Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 16th, 2003, 05:34 AM
Registered User
 
Join Date: Jul 2003
Location: Chennai, Tamilnadu, India.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to pcshan
Default What is an alternative for Response.Redirect

Dear ASPians,

Plz suggest me the way in which i can use Respose.Redirect in the web site which uses frames.

If there is any method, plz tell me the way of sending querystring using that method, like

Response.Redirect "Login.asp?error="&error

Thanking you!

with regards,
Shan

 
Old July 16th, 2003, 11:10 AM
Imar's Avatar
Wrox Author
Points: 70,322, Level: 100
Points: 70,322, Level: 100 Points: 70,322, Level: 100 Points: 70,322, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

I take it you are trying to redirect form a sub frame to the parent frame, right??
If that's the case, you'll need to send some JavaScript to the browser to do the redirect, like this:

Code:
Response.Write("<scr" & "ipt language=""JavaScript"" type=""text/javascript"">" & vbCrLf
Response.Write(vbTab & "top.location.href='" & YourRedirectPage & "';" & vbCrLf
Response.Write("</scr" & "ipt>")
I split up the <script> tags to make sure that your ASP page doesn't get confused by an ending (server side) script tag.

This code sends the required JavaScript to the browser, telling it to load the page YourRedirectPage in the top frame.

Alternatively, you can make login.asp redirect itself to the .top. Personally, I prefer the first option however.

HtH

Imar


---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old July 23rd, 2003, 05:53 AM
Registered User
 
Join Date: Jul 2003
Location: Chennai, Tamilnadu, India.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to pcshan
Default

Thank u Imar, I'll try it out and get back to u. - shan
 
Old April 28th, 2004, 02:10 PM
Registered User
 
Join Date: Apr 2004
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Instead of top.location.href try also parent.location.href. The later worked for me as I wanted.

Alex Diaz
Miami, FL




Similar Threads
Thread Thread Starter Forum Replies Last Post
Response.Redirect in c# class. manish.sharma04 BOOK: Professional ASP.NET 2.0 and Special Edition; ISBN: 978-0-7645-7610-2; ISBN: 978-0-470-04178-9 17 February 28th, 2012 07:01 PM
response.redirect sarah lee ASP.NET 1.0 and 1.1 Basics 1 October 27th, 2006 08:57 AM
response.redirect ava_h .NET Framework 2.0 0 October 18th, 2006 10:21 PM
response.redirect crmpicco Classic ASP Basics 3 February 9th, 2005 01:50 AM
Response.Redirect dhborchardt Classic ASP Basics 4 June 16th, 2003 05:56 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.