How to access div on wicket modal dialog
Hi, I'm using a wicket modal dialog with the panel that contains a div container like div id=slider/div I want to access it from jQuery to create a jQuery UI slider like $(#slider).slider(); For some reason, this doesn't work. Is there some reason related to wicket that prevents this to find div container using its id, because the same thing works fine when I use jQuery modal dialog instead of wicket modal dialog? Zoran -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/How-to-access-div-on-wicket-modal-dialog-tp2310678p2310678.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: How to access div on wicket modal dialog
if you open a page inside modal then the markup is in a different window so you have to make sure your jquery script executes in the right window. if you are using a panel and the markup is rendered in the same window it means your script is probably running too early. -igor On Mon, Aug 2, 2010 at 11:00 AM, zoran jeremy...@gmail.com wrote: Hi, I'm using a wicket modal dialog with the panel that contains a div container like div id=slider/div I want to access it from jQuery to create a jQuery UI slider like $(#slider).slider(); For some reason, this doesn't work. Is there some reason related to wicket that prevents this to find div container using its id, because the same thing works fine when I use jQuery modal dialog instead of wicket modal dialog? Zoran -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/How-to-access-div-on-wicket-modal-dialog-tp2310678p2310678.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: How to access div on wicket modal dialog
Igor, You save my life :) if you are using a panel and the markup is rendered in the same window it means your script is probably running too early. That is exactly what was the problem. I added response.renderOnDomReadyJavascript(js); In AbstractBehavior RenderHead method, and everything works like it should work. Thanks, Zoran -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/How-to-access-div-on-wicket-modal-dialog-tp2310678p2310845.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: How to access div on wicket modal dialog
thats what i do...save lives :) -igor On Mon, Aug 2, 2010 at 12:50 PM, zoran jeremy...@gmail.com wrote: Igor, You save my life :) if you are using a panel and the markup is rendered in the same window it means your script is probably running too early. That is exactly what was the problem. I added response.renderOnDomReadyJavascript(js); In AbstractBehavior RenderHead method, and everything works like it should work. Thanks, Zoran -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/How-to-access-div-on-wicket-modal-dialog-tp2310678p2310845.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org