updating CSS with p:slider

UI Components for JSF
Post Reply
vished
Posts: 479
Joined: 02 Feb 2014, 17:38

05 Jul 2014, 01:55

Hello,

I want to update the width with the p:slider.
But it doesn´t work. I debug with firebug. The txt3 and txt4 will change the value. But my <p:outputPanel id="test" doesn´t change the value in the style attribute.

Here my code:
Bean: + Getter/ Setter
private int marginLeft = 30;
private int marginRight = 80;

Code: Select all

		<h:outputText id="displayRange"
							value="Between #{documentTemplateEditController.marginLeft} and #{documentTemplateEditController.marginRight}" />
						<p:slider for="txt3,txt4,test" type="horizontal"
							display="displayRange"
							styleClass="documentTemplateEditorSliderHorizontal" range="true" />
						<h:inputHidden id="txt3"
							value="#{documentTemplateEditController.marginLeft}" />
						<h:inputHidden id="txt4"
							value="#{documentTemplateEditController.marginRight}" />

						<p:outputPanel id="test"
							style="margin-left: #{documentTemplateEditController.marginLeft}px;" />
PF 8.0

vished
Posts: 479
Joined: 02 Feb 2014, 17:38

17 Oct 2014, 08:48

Any ideas?
PF 8.0

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 44 guests