-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Expand file tree
/
Copy pathindex.xhtml
More file actions
133 lines (109 loc) · 5.5 KB
/
index.xhtml
File metadata and controls
133 lines (109 loc) · 5.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://xmlns.jcp.org/jsf/html"
xmlns:f="http://xmlns.jcp.org/jsf/core">
<h:head>
<title>Facelet Title</title>
</h:head>
<h:body>
<h1>JSF Components</h1>
<h:form prependId="false">
<b>commandButton</b><br/>
<h:commandButton value="Next" action="next"/>
<p/><b>commandLink</b><br/>
<h:commandLink value="myLink" action="next"/>
<p/><b>dataTable</b><br/>
<h:dataTable value="#{myBean.list}" var="p">
<h:column>
<f:facet name="header">Id</f:facet>
#{p.id}
</h:column>
<h:column>
<f:facet name="header">Name</f:facet>
#{p.name}
</h:column>
</h:dataTable>
<p/><b>graphicImage</b><br/>
<h:graphicImage value="/images/glassfish.png"/>
<p/><b>inputHidden</b><br/>
<h:inputHidden value="myHiddenValue"/>
<p/><b>inputSecret</b><br/>
<h:inputSecret value="#{myBean.password}"/>
<p/><b>inputText</b><br/>
<h:inputText id="myInputText" value="#{myBean.inputText}"/>
<p/><b>inputTextArea</b><br/>
<h:inputTextarea value="#{myBean.inputTextarea}"/>
<p/><b>button</b><br/>
<h:button value="myButton" outcome="next"/>
<p/><b>link</b><br/>
<h:link value="Next" outcome="next">
<f:param name="foo" value="bar"/>
</h:link>
<p/><b>outputFormat</b><br/>
<h:outputFormat value="Hello {0}">
<f:param value="Duke"/>
</h:outputFormat>
<p/><b>outputLabel</b><br/>
<h:outputLabel for="inputTextId" value="myLabel"/>
<h:inputText id="inputTextId" value="myInputText"/>
<p/><b>outputLink</b><br/>
<h:outputLink value="next.xhtml">myOutput</h:outputLink>
<p/><b>outputText</b><br/>
<h:outputText value="myOutputText"/>
<p/><b>outputScript</b><br/>
<h:outputScript library="scripts" name="main.js"/>
<p/><b>outputStylesheet</b><br/>
<h:outputStylesheet library="stylesheets" name="main.css"/>
<p/><b>panelGrid</b><br/>
<h:panelGrid columns="2">
<h:outputLabel for="inputText1" value="myLabel1"/>
<h:inputText id="inputText1" value="#{myBean.inputText}"/>
<h:outputLabel for="inputText2" value="myLabel2"/>
<h:inputText id="inputText2" value="#{myBean.inputText}"/>
</h:panelGrid>
<p/><b>selectBooleanCheckbox</b><br/>
<h:selectBooleanCheckbox value="#{myBean.selectBooleanCheckbox}"/>
<p/><b>selectOneRadio</b><br/>
<h:selectOneRadio value="#{myBean.selectBooleanCheckbox}">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
</h:selectOneRadio>
<p/><b>selectOneListbox</b><br/>
<h:selectOneListbox value="#{myBean.selectBooleanCheckbox}">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
</h:selectOneListbox>
<p/><b>selectOneMenu</b><br/>
<h:selectOneMenu value="#{myBean.selectBooleanCheckbox}">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
</h:selectOneMenu>
<p/><b>selectManyCheckbox</b><br/>
<h:selectManyCheckbox value="#{myBean.selectManyCheckbox}">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
</h:selectManyCheckbox>
<p/><b>selectManyListbox</b><br/>
<h:selectManyListbox value="#{myBean.selectManyCheckbox}" size="2">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
<f:selectItem itemValue="yellow" itemLabel="Yellow"/>
<f:selectItem itemValue="orange" itemLabel="Orange"/>
</h:selectManyListbox>
<p/><b>selectManyMenu</b><br/>
<h:selectManyMenu value="#{myBean.selectManyCheckbox}">
<f:selectItem itemValue="red" itemLabel="Red"/>
<f:selectItem itemValue="green" itemLabel="Green"/>
<f:selectItem itemValue="blue" itemLabel="Blue"/>
<f:selectItem itemValue="yellow" itemLabel="Yellow"/>
<f:selectItem itemValue="orange" itemLabel="Orange"/>
</h:selectManyMenu>
</h:form>
</h:body>
</html>