Re: [Wicket-user] Betr.: Re: IFrame + PageMap
ahhthe meta stuff is not cleared! Thats a bug.johanOn 11/14/06, Marieke Vandamme <[EMAIL PROTECTED] > wrote: The first time I set the src of the iframe, it doesn't happen indeed. I tried to remove the pagemap, but with no luck. My code now looks like this : PageMap.forName("subpage").remove(); iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); When debugging public final void renderHead(final Response response) in WebPage, "subpage" is still an entry of meta.pageMapNames... "Johan Compagner" <[EMAIL PROTECTED]> Verzonden door: [EMAIL PROTECTED] 14/11/2006 13:50 Antwoord a.u.b. aan wicket-user@lists.sourceforge.net Aan wicket-user@lists.sourceforge.net Cc Onderwerp Re: [Wicket-user] IFrame + PageMap Does it really happen the first time you open that iframe? (i mean really the very first time) if it then goes fine then you could do this right before: iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); do this: PageMap.forName("subpage").remove(); So make sure there is no old subpage pagemap hanging around. johan On 11/14/06, Marieke Vandamme <[EMAIL PROTECTED] > wrote: Hello, I'm having difficulties using iframe inside a webpage, as the destination page of my iframe is loaded twice. Example code: MainPage.html MainPage.java private WebMarkupContainer iFrame = null; public MainPage() { iFrame = new WebMarkupContainer("iFrame"); iFrame.setOutputMarkupId(true); add(iFrame); Form webForm = new Form("webForm"); webForm.add(new AjaxSubmitButton("btnSubmit", webForm){ protected void onSubmit(AjaxRequestTarget target, Form form) { iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); target.addComponent(iFrame); } }); add(webForm); } There will be two SubPage-instances created with different pagemap (first time "subpage", second time "wicket-0"). When looking into this, I saw in the wicket.markup.html.WebPage, that the location is set again with different pagemap. I tried also 2 other options : 1. Set the pagemap in the constructor of the SubPage : super(PageMap.forName("subpage")); 2. Use wicket.markup.html.link.InlineFrame instead of WebMarkupContainer. With this last one, I'm not sure I implemented it right. iFrame = new InlineFrame("iFrame", PageMap.forName("subpage"), SubPage.class); // I want an empty iframe the first time iFrame.add(new SimpleAttributeModifier("src", "")); iFrame = new WebMarkupContainer("iFrame"); iFrame.setOutputMarkupId(true); add(iFrame); Form webForm = new ... When testing all the above, sometimes I ran into a neverending cycle, because the window.location is set everytime. What is the solution? I know that using no iframes is the best one, but I have a searchbox + underneath my results. Only the results may be scrollable, so the searchbox is always visible. Thanks in advance ! 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." - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Betr.: Re: IFrame + PageMap
Hello, Did you already try to set the src attribute to "about:blank" the first time? This works in IE and FireFox, not sure about other browsers. Alternatively, you can create a special page that is empty. Erik. Marieke Vandamme schreef: > > The first time I set the src of the iframe, it doesn't happen indeed. > > I tried to remove the pagemap, but with no luck. > > My code now looks like this : > PageMap.forName("subpage").remove(); > iFrame.add(new SimpleAttributeModifier("src", > urlFor(PageMap.forName("subpage"), SubPage.class, null))); > > When debugging > public final void renderHead(final Response response) > in WebPage, "subpage" is still an entry of meta.pageMapNames... > -- Erik van Oosten http://www.day-to-day-stuff.blogspot.com/ - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
[Wicket-user] Betr.: Re: IFrame + PageMap
The first time I set the src of the iframe, it doesn't happen indeed. I tried to remove the pagemap, but with no luck. My code now looks like this : PageMap.forName("subpage").remove(); iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); When debugging public final void renderHead(final Response response) in WebPage, "subpage" is still an entry of meta.pageMapNames... "Johan Compagner" <[EMAIL PROTECTED]> Verzonden door: [EMAIL PROTECTED] 14/11/2006 13:50 Antwoord a.u.b. aan wicket-user@lists.sourceforge.net Aan wicket-user@lists.sourceforge.net Cc Onderwerp Re: [Wicket-user] IFrame + PageMap Does it really happen the first time you open that iframe? (i mean really the very first time) if it then goes fine then you could do this right before: iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); do this: PageMap.forName("subpage").remove(); So make sure there is no old subpage pagemap hanging around. johan On 11/14/06, Marieke Vandamme <[EMAIL PROTECTED]> wrote: Hello, I'm having difficulties using iframe inside a webpage, as the destination page of my iframe is loaded twice. Example code: MainPage.html MainPage.java private WebMarkupContainer iFrame = null; public MainPage() { iFrame = new WebMarkupContainer("iFrame"); iFrame.setOutputMarkupId(true); add(iFrame); Form webForm = new Form("webForm"); webForm.add(new AjaxSubmitButton("btnSubmit", webForm){ protected void onSubmit(AjaxRequestTarget target, Form form) { iFrame.add(new SimpleAttributeModifier("src", urlFor(PageMap.forName("subpage"), SubPage.class, null))); target.addComponent(iFrame); } }); add(webForm); } There will be two SubPage-instances created with different pagemap (first time "subpage", second time "wicket-0"). When looking into this, I saw in the wicket.markup.html.WebPage, that the location is set again with different pagemap. I tried also 2 other options : 1. Set the pagemap in the constructor of the SubPage : super(PageMap.forName("subpage")); 2. Use wicket.markup.html.link.InlineFrame instead of WebMarkupContainer. With this last one, I'm not sure I implemented it right. iFrame = new InlineFrame("iFrame", PageMap.forName("subpage"), SubPage.class); // I want an empty iframe the first time iFrame.add(new SimpleAttributeModifier("src", "")); iFrame = new WebMarkupContainer("iFrame"); iFrame.setOutputMarkupId(true); add(iFrame); Form webForm = new ... When testing all the above, sometimes I ran into a neverending cycle, because the window.location is set everytime. What is the solution? I know that using no iframes is the best one, but I have a searchbox + underneath my results. Only the results may be scrollable, so the searchbox is always visible. Thanks in advance ! 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." - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
[Wicket-user] Betr.: Re: IFrame + PageMap
Hello, Thx for the reply. I thought about that first, but i need to take all the space i can use (width:100%; height:100%) and the "overflow:scroll;" option isn't working then (at least not in all browsers, Firfox doesn't support it). Marieke. Erik van Oosten <[EMAIL PROTECTED]> Verzonden door: [EMAIL PROTECTED] 14/11/2006 13:44 Antwoord a.u.b. aan wicket-user@lists.sourceforge.net Aan wicket-user@lists.sourceforge.net Cc Onderwerp Re: [Wicket-user] IFrame + PageMap Hello Marieke, I can not help you with the IFrame problem, but you can also use a div with the following style: width: ...; height:...; overflow: scroll; Erik. Marieke Vandamme wrote: > What is the solution? I know that using no iframes is the best one, > but I have a searchbox + underneath my results. > Only the results may be scrollable, so the searchbox is always visible. > -- Erik van Oosten http://www.day-to-day-stuff.blogspot.com/ - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ 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." - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user