You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Doug Leeper <do...@yahoo.com> on 2010/04/16 17:50:43 UTC

Interstitial window prompt then open a new window

We are needing an interstitial window that prompts a user if they want to continue to another site.  Additionally, we would like to provide a checkbox if they would  not longer like to see this prompt again.
I can prompt via a ModalWindow and capture their response...but what I am not sure what to do now is open a window with the destination URL via Ajax.

I like the target="_blank" behavior on an href...but this can't apply since I am opening a modal window with that link.  Do I have to create custom javascript to append to the Ajax request to open a new window with that url?

Are there other options?

Thanks in advance!
- Doug

RE: Interstitial window prompt then open a new window

Posted by Jeffrey Schneller <je...@envisa.com>.
You may want to look into this.  I am using this to send a user to page
off our site via a link.

		Link myLink = new Link("myLink") {
			@Override
			public void onClick() {
				String url = "http://your_url";
				throw new
RestartResponseAtInterceptPageException(new RedirectPage(url)); 
			}
			
		};
	    	PopupSettings settings = new PopupSettings();
	    	settings.setTarget("_new");
	    	settings.setWindowName("My Other Site");
	    	myLink.setPopupSettings(settings);
		add(myLink);


It does not have the interstitial window prompt but this may get your
closer to what you want.



-----Original Message-----
From: Doug Leeper [mailto:dougleeper@yahoo.com] 
Sent: Friday, April 16, 2010 11:51 AM
To: users@wicket.apache.org
Subject: Interstitial window prompt then open a new window

We are needing an interstitial window that prompts a user if they want
to continue to another site.  Additionally, we would like to provide a
checkbox if they would  not longer like to see this prompt again.
I can prompt via a ModalWindow and capture their response...but what I
am not sure what to do now is open a window with the destination URL via
Ajax.

I like the target="_blank" behavior on an href...but this can't apply
since I am opening a modal window with that link.  Do I have to create
custom javascript to append to the Ajax request to open a new window
with that url?

Are there other options?

Thanks in advance!
- Doug

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org