-
1. Display list of values horizontally using rich:dataList
boy18nj Mar 3, 2011 10:18 PM (in response to sd1)your best easy bet is, concatenate the values as string in your managed bean- activity.lane
-
2. Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 5:00 AM (in response to boy18nj)Use ui:repeat/a4j:repeat but without "<li>".
Look at this example: http://www.w3schools.com/TAGS/tryit.asp?filename=tryhtml_list_test
-
3. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 9:35 AM (in response to boy18nj)Hi Aman,
Thanks for the reply. I have to display an image for each number displayed hirizontally.like..and vales(numbers) change(increase or decrease) depending on the activity selected from the dropdown
1 2 3
So I dont think Concatenation helps in this case, please let me know if im wrong.
I have also used
<h:dataTable id="dt2" value="#{ActivitySummaryBean.Activities}" var="activity" >
<h:column>
<f:facet name="header">
<h:outputText value=" Id" />
</f:facet>
<h:outputText value="#{activity.lane}"/>
</h:column>
<h:column>
<h:graphicImage id="u-turn" value="../styles/icons/turn.gif" />
</h:column>
</h:dataTable>
Using h:datatable, the values/images are displaying vertically like:
1
2
3
Thanks
-
4. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 9:39 AM (in response to ilya40umov)I tried without "<li>" , its still not working.
-
5. Re: Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 9:43 AM (in response to sd1)Please post the recent code with ui:repeat and result which is obtained in browser(html).
-
6. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 9:47 AM (in response to ilya40umov)Here is the code,
<ui:repeat items="#{ActivitySummaryBean.Activities}" var="activity">
<h:outputText value="#{activity.lane}"/>
</ui:repeat>
webpage didnot display for this. it gave me http error.
-
7. Re: Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 9:52 AM (in response to sd1)What kind of error?
-
8. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 10:06 AM (in response to ilya40umov)This error (HTTP 500 Internal Server Error) means that the website you are visiting had a server problem which prevented the webpage from displaying.
-
9. Re: Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 10:17 AM (in response to sd1)=) I meant this: Could you provide the full stack trace of the exception?
-
10. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 10:35 AM (in response to ilya40umov)Sorry,
[3/4/11 10:29:05:610 EST] 00000023 WebApp E [Servlet Error]-[Faces Servlet]: com.sun.facelets.tag.TagException: /activitysummary/lane_activity_summary.jsp @63,81 <ui:repeat> Tag Library supports namespace: http://java.sun.com/jsf/facelets, but no tag was defined for name: repeat
at com.sun.facelets.compiler.CompilationManager.pushTag(CompilationManager.java:155)
at com.sun.facelets.compiler.SAXCompiler$CompilationHandler.startElement(SAXCompiler.java:185)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:379)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:176)
at com.sun.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:222)
at com.sun.facelets.compiler.Compiler.compile(Compiler.java:105)
at com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:189)
at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:138)
at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:89)
at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:401)
at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:442)
at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:100)
at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:176)
at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110)
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
-
11. Re: Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 11:37 AM (in response to sd1)1) try a4j:repeat
2) probably you have old implementation of facelets. try facelets 1.1.15.B1
-
12. Re: Display list of values horizontally using rich:dataList
sd1 Mar 4, 2011 12:02 PM (in response to ilya40umov)Hi I have used,
<a4j:repeat value="#{ActivitySummaryBean.Activities}" var="activity" >
<h:outputText value="#{activity.lane}"></h:outputText>
</a4j:repeat>
i am not getting values in the page
-
13. Re: Display list of values horizontally using rich:dataList
ilya40umov Mar 4, 2011 12:07 PM (in response to sd1)it's very strange.
1) Provide your JSF/RF/Facelets versions
2) What html code do you have in a browser for the following lines?
<a4j:repeat value="#{ActivitySummaryBean.Activities}" var="activity" >
<h:outputText value="#{activity.lane}"></h:outputText>
</a4j:repeat>