Applying styles to dynamic tree is not working

UI Components for JSF
Post Reply
codo
Posts: 5
Joined: 02 Nov 2010, 10:37

02 Nov 2010, 10:50

Hello guys,

I want to apply some css styles to the dynamic tree. Here is short example of what I'm trying to do:

Code: Select all

            <p:tree value="#{treeBean.root}" var="node" dynamic="true">
                <p:treeNode>
                    <h:outputText value="#{node}" style="padding-left: 20px;"/>
                </p:treeNode>
            </p:tree>
When I load the page, the tree is shown but when I try to expand one of the root nodes it starts loading and nothing happens (just loading...). This also happens when I try to put h:outputLink (or whatever tag, different from h:outputText) in the p:treeNode tag.

Any help will be appreciate!

Thank you!

codo
Posts: 5
Joined: 02 Nov 2010, 10:37

02 Nov 2010, 22:56

Hello again,

I rolled back the version of PrimeFaces from 2.2.RC1 to 2.1 and it does work now..

KingdomHeart
Posts: 280
Joined: 25 Jun 2010, 01:18

02 Nov 2010, 23:39

does taking out the "style" attribute solve the problem? Show case seems to work fine
http://www.primefaces.org/showcase/ui/treeAjax.jsf

Mojarra 2.1.10, Glassfish 3.1, Tomcat 7, Primeface 3.3.1
IE 6-8, FireFox 10-13
MAC OSX Lion, Windows XP, 7

codo
Posts: 5
Joined: 02 Nov 2010, 10:37

03 Nov 2010, 11:59

Yes. But When you want to style the h:outputText it doesn't work with version 2.2.RC1. And it also doesn't work when you try to put other tag in the treeNode, for example h:outputLink.

codo
Posts: 5
Joined: 02 Nov 2010, 10:37

03 Nov 2010, 12:07

By the way, does anyone experience this problem ? I'm using:
primefaces version 2.2.RC1
GlassFish Server 3
Windows XP Professional x64

Thank you!

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 29 guests