views:

406

answers:

2

I'm trying to do this in a way that will prevent end-user browser security features (such as a pop-up blocker) from getting in the way of my application.

+2  A: 

There is no way to disable pop-up blockers to prevent opening pop-ups.

Why do you want to use Response.Redirect? I find its best to inject javascript using this method:

ScriptManager.RegisterStartupScript(this.Page, this.GetType(), "PopUp", "window.open([url]);", true);

Another possibility is to use a modal dialog or floating iframe window to show other content on the current page. jQuery is great for this.

For example, check out jQuery impromptu if you're interested in simple messages/dialogs

jQuery Impromptu

KClough
The JQuery UI Forms does the same thing (if you have already gone down the JQuery road) and comes straight from the JQuery guys. http://jqueryui.com/demos/dialog/
Chris Brandsma
Thanks Chris! Wasn't aware of that one, I really need to spend some time to go through everything in the UI package.
KClough
+1  A: 

"Use for a pop-up" how? You want the redirect to create the pop-up?

That can't be done. A redirect is a return status from the request made by a particular browser window. Responses don't create windows.

John Saunders
Ahh, I'm kindof a noob here. That makes sense.
Giffyguy