Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Redirect out of a Frameset
If a page runnning in a frame does a redirect, the new page is loaded into
the same frame.

How do I do a redirect that 'looses' the frameset?

In html, you can create a link with "target=_top" and it replaces the entire
frameset.

But a reponse.redirect("NewPage.aspx Target=_top") becomes:
http://server/NewPage.aspx%20Target=_top

How do I do this?  Can I stop it from parsing the space into %20, or is
there a different method altogether I should use?

David
--
David Gordon-Brown

Report this thread to moderator Post Follow-up to this message
Old Post
David GB
12-24-04 08:55 AM


Re: Redirect out of a Frameset
You could send back a HTML page with some javascript to load your
required URL into the top level window.
Should not mess with the history list.

<script type="text/javascript">
top.location.replace( "yourURLHere" );
</script>


Tim.


"David GB" <DavidGB@discussions.microsoft.com> wrote in message
news:326D92A9-3038-41D9-915E-828B7C477A6C@microsoft.com...
> If a page runnning in a frame does a redirect, the new page is
> loaded into
> the same frame.
>
> How do I do a redirect that 'looses' the frameset?
>
> In html, you can create a link with "target=_top" and it replaces
> the entire
> frameset.
>
> But a reponse.redirect("NewPage.aspx Target=_top") becomes:
> http://server/NewPage.aspx%20Target=_top
>
> How do I do this?  Can I stop it from parsing the space into %20, or
> is
> there a different method altogether I should use?
>
> David
> --
> David Gordon-Brown



Report this thread to moderator Post Follow-up to this message
Old Post
Tim Williams
12-24-04 08:55 AM


Re: Redirect out of a Frameset
Smart idea. Thanks.

I would put that into the page 'OnLoad' procedure, right?

Could it trigger pop-up blockers, though?

"Tim Williams" wrote:

> You could send back a HTML page with some javascript to load your
> required URL into the top level window.
> Should not mess with the history list.
>
> <script type="text/javascript">
> top.location.replace( "yourURLHere" );
> </script>
>
>
> Tim.
>
>
> "David GB" <DavidGB@discussions.microsoft.com> wrote in message
> news:326D92A9-3038-41D9-915E-828B7C477A6C@microsoft.com... 
>
>
>

Report this thread to moderator Post Follow-up to this message
Old Post
David GB
12-27-04 08:55 AM


Re: Redirect out of a Frameset
David,

If you just put it in the page it will execute without having to be
called from onload.  AFAIK it will not trigger pop-up blockers since
you are not opening a new window.  It will, however, fail if the user
has js disabled or is not using a js-capable browser, so beware of
that.

Tim.


"David GB" <DavidGB@discussions.microsoft.com> wrote in message
news:8C609857-494C-4370-B44B-0D9918D6A981@microsoft.com...
> Smart idea. Thanks.
>
> I would put that into the page 'OnLoad' procedure, right?
>
> Could it trigger pop-up blockers, though?
>
> "Tim Williams" wrote:
> 



Report this thread to moderator Post Follow-up to this message
Old Post
Tim Williams
12-27-04 08:55 AM


Re: Redirect out of a Frameset
Thanks.  Very helpful.

David

"Tim Williams" wrote:

> David,
>
> If you just put it in the page it will execute without having to be
> called from onload.  AFAIK it will not trigger pop-up blockers since
> you are not opening a new window.  It will, however, fail if the user
> has js disabled or is not using a js-capable browser, so beware of
> that.
>
> Tim.
>
>
> "David GB" <DavidGB@discussions.microsoft.com> wrote in message
> news:8C609857-494C-4370-B44B-0D9918D6A981@microsoft.com... 
>
>
>

Report this thread to moderator Post Follow-up to this message
Old Post
David GB
12-28-04 01:55 AM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

ASP archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 08:22 AM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.