Hi, I am working with modals in my application, for this I have done my own mixin that uses *colorbox* for the modal.
My problem, right now is that I have a form in one of those modals that has to redirect when is submited. I have two methods in the class: @Inject private JavaScriptSupport javaScriptSupport; void onValidateFromAddRouteForm() throws ValidationException{ all the validations... } Object onSuccess(){ //Adding the script to close the modal and forwarding the "parent iframe". javaScriptSupport.addScript("jQuery.colorbox.close();"); return ShowRoutePlan.class; } When I get to the succes and want to close with the modal iframe I have this run time error: No object of type org.apache.tapestry5.services.javascript.JavaScriptSupport is available from the Environment. I have read something about not being able to add javascriptSupport on render methods or something like that, but I am not sure if this is just one of those cases where I just can't use javascriptSupport. If it is, how can I add the javascript function for closing the page? Or to redirect the parent instead of the iframe. Cheers and Thanks in advance!