Solved

server.transfer url problem?

Posted on 2002-05-18
2
199 Views
Last Modified: 2008-03-04
when doing a server.transfer using ASP.NET, the URL does not change to the new location... it stays set to the original location the user pointed to.

for example, user goes to http://www.somedomain.com/default.aspx, server.transfer redirects to http://www.somedomain.com/intro.htm. yet the URL in the browser address bar stays set to http://www.somedomain.com/default.aspx.

why is this? and is it a problem?

and does the browser contain the real transfered-to URL, but happens to show the wrong one?

thanks!
0
Comment
Question by:loyaliser
2 Comments
 
LVL 23

Accepted Solution

by:
naveenkohli earned 75 total points
ID: 7018465
When you do Server.Transfer, the execution of thread shifts to new page. The execution of previous thread is not terminated. All the headers, response from redirecting page is carried on to new page. Where as when you do Response.Redirect, the execution of thread is terminated. You can do a very simple experiement. Call Response.Redirect but put the call within try/catch block and you will see that ThreadAbort exception is thrown. This is due to termination of current execution thread.

There is no problem with what you are observing.

Naveen
0
 
LVL 1

Author Comment

by:loyaliser
ID: 7018559
ok... that makes sense.

thanks!
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now