[Building Sakai] sakai open new window

Steve Swinsburg steve.swinsburg at gmail.com
Tue Nov 3 14:22:36 PST 2009


Hi Tania,

For 1, you should just be able to render the Wicket Link with the
target="_blank" attribute in the html? This will open a new window.
<a href="#" wicket:id="myLink" target="_blank" />

For 2, You'll need to use an AjaxButton so you have access to Wicket's
AjaxRequestTarget, then just do this:

target.appendJavascript("setMainFrameHeight(window.name);");


This method comes from Sakai's header scripts, so assuming you've included
them, you should be right. If not, have a look here for a BasePage I use in
Profile2 which all subpages extend:
https://source.sakaiproject.org/contrib//profile2/trunk/tool/src/java/org/sakaiproject/profile2/tool/pages/BasePage.java

cheers,
Steve


On Wed, Nov 4, 2009 at 2:37 AM, Tania Tritean <ttritean at loi.nl> wrote:

>  Hi,
>
> I have 2 questions, if you can help me:
>
>
>
>    1. From a sakai page, from inside of a iframe, when I click a link I
>    want to open a page with a given url in a new browser window, so not inside
>    sakai. How can I do this?(I’m using wicket)
>    2. How can I modify the height of an iframe from sakai, after the page
>    was rendered.(eq. I have the frame with size x, and when I click a button I
>    want to make the frame bigger)
>
>
>
>
>
> Thanks a lot
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20091104/dc739b2b/attachment.html 


More information about the sakai-dev mailing list