Logo 
Search:

Java Forum

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds

Another JSF question

  Asked By: Nisha    Date: Apr 11    Category: Java    Views: 725
  

Here I am again with another JSF question.Thanks guys for helping me out.
I have used this jsf code but It puts the textBox in next line, Any help is appreciated.


<tr>
<td >
<h:selectOneRadio layout="pageDirection" id="myRadioButton">
<f:selectItem itemValue="0" itemLabel="Not Specified"/>
<f:selectItem itemValue="1" itemLabel="Person:"/>
</h:selectOneRadio>

<h:inputText id="myTextBox" required="true" />
</td>
</tr>

Share: 

 

2 Answers Found

 
Answer #1    Answered By: Lewis Welch     Answered On: Apr 11

never use HTML tags!! JSF provides you a wide range of tags, instead of <TR> try to utilize <h:panelGrid>

 
Answer #2    Answered By: Mike Stephens     Answered On: Apr 11

if you want to do it with HTML table, you can write the following:


<f:view>
<table border="1">
<tr>
<td>
<h:selectOneRadio layout="pageDirection" id="myRadioButton">
<f:selectItem itemValue="0" itemLabel="Not Specified"/>
<f:selectItem itemValue="1" itemLabel="Person: "/>
</h:selectOneRadio>
</td>
<td valign="bottom">
<h:inputText id="myTextBox" required="true" />
</td>
</tr>
</table>
</f:view>

i have set the table border to 1 to see what is happening.

 
Didn't find what you were looking for? Find more on Another JSF question Or get search suggestion and latest updates.




Tagged: