you sure you dont have an exception somewhere...check the console/logs for a
stacktrace

-igor


On 6/21/07, Marieke Vandamme <[EMAIL PROTECTED]> wrote:


Do I need to report the problem with writing javascript to inlineframe on
jira?
Or is this already a known issue...
Thanks !



 *Marieke Vandamme <[EMAIL PROTECTED]>*
Verzonden door: [EMAIL PROTECTED]

20/06/2007 14:00  Antwoord a.u.b. aan
wicket-user@lists.sourceforge.net

  Aan
wicket-user@lists.sourceforge.net  Cc

 Onderwerp
[Wicket-user] Write javascript to inlineframe







Hello,

On my html page I have an iframe => <iframe wicket:id="iframe"></iframe>

Early code :
WebMarkupContainer iframe = new WebMarkupContainer("iframe");
Then I set the src for my iframe with a SimpleMarkupContainer =>
iframe.add(new SimpleAttributeModifier("src", 
urlFor(PageMap.forName("MyPageMap"),
MyPage.class, params)));

New code (i want to change and use inlineframe):
InlineFrame iframe = InlineFrame("iframe", PageMap.forName("MyPageMap"),
MyPage.class);

Problem:
In MyPage.java I want to write some javascript to my html using
JavascriptUtils.writeJavascript.
This works fine, untill I put a form on my FirstPage (the page that holds
the iframe).
Without the form, the javascript is printed in my iframe, with the form,
it isn't...
Is this expected behaviour when form and iframe are on the same page?
When using my early code (with the simpleattributemodifier i don't have
any problems)..

I need my form, because my form contains an ajaxsubmitbutton and with this
button i want to refresh my iframe.
There I have another question..
Is the code underneath the best solution to do so or is there a better
one?

AjaxSubmitButton btn = new AjaxSubmitButton("btn", myForm) {
     protected void onSubmit(AjaxRequestTarget target, Form form) {
       final InlineFrame newIframe = InlineFrame("iframe", 
PageMap.forName("MyPageMap"),
MyPage.class);
       newIframe.setOutputMarkupId(true);
       newIframe.replaceWith(iframe);
       target.addComponent(newIframe);
     }
   };  **** DISCLAIMER *****
**
http://www.tvh.be/newen/pages/emaildisclaimer.html 
*<http://www.tvh.be/newen/pages/emaildisclaimer.html>

"This message is delivered to all addressees subject to the conditions
set forth in the attached disclaimer, which is an integral part of this
message."
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.

http://sourceforge.net/powerbar/db2/_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

**** DISCLAIMER ****

http://www.tvh.be/newen/pages/emaildisclaimer.html

"This message is delivered to all addressees subject to the conditions
set forth in the attached disclaimer, which is an integral part of this
message."

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to