Hi there, have a look at IHeaderContributor. There's an easy example in the API docs.
http://wicket.apache.org/docs/wicket-1.3.2/wicket/apidocs/org/apache/wicket/markup/html/IHeaderContributor.html Cheers tleveque wrote: > > Hi > > I am kind of new to the wicket framework... > > But here is what I am trying to do: > I am implementing a part of an already existing application. > In this new section, I have a form, when it is submitted, if some > conditions are respected, I need to call an already existing javascript > function (that will modify something in another frame). > It is not and cannot be a ajax call. > It need to be conditional to something on the server side. > > In our pre-wicket version of this section, a "<script>" markup was just > added a the end of the page by a condition in the jsp. > > What is the best way to do that kind of thing? > I found a solution by overrinding the "onBeforeRender" method on my page > and use "getResponse().write( "<script>functionxy();</script>" );" based > on a flag I set in my button's "onSubmit" method, but I find it kind of > ugly..... Is there another way? A cleaner way? > > Thanks! > -- View this message in context: http://www.nabble.com/Calling-a-javascript-function-on-render-tp19414820p19414825.html Sent from the Wicket - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
