Hiding WebPage name in address bar

C

Craig Deelsnyder

Hi,

I don't want to show the web page name shown in the address bar.
For example if the website address is http://localhost/webreadfile/ so
from
this point forward, no matter which pages I surf, the address bar should
look like http://localhost/webreadfile/. It should not show any page
name.

Thanks

Most often this is done with frames/iframe. Otherwise you'd have to do
some sort of URL rewriting (which is possible), but you'd still need
unique URLs for that (albeit more minor changes).
 
J

John Timney \(ASP.NET MVP\)

Why would you ever want to do this, it makes no sense to confuse the user as
to where they are in an application?

You could load a frameset with your site inside another inside a parent
frameset and the URL will not change on the parent.even though the pages in
the child change, or simply launch your site into a window with no chrome

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director
 
M

Mustufa Baig

Okay. Got it!

I don't want to let users click back button. One way is to hide the tool bar
thru javascript. I can acheive it only when the user clicks on a link and
website opens in a new in a new window. But let say users are not clicking a
link to get to my website, they are actually getting to it by typing website
address. In this case I don't know how to make the toolbar disappear.

Could you please give me some suggestions on this?

Thanks
 
K

Kevin Spencer

The address bar is going to show the URL of the page you are looking at. In
your example, apparently the page is a default page for the virtual
directory it lives in. Otherwise, the file name would appear in the URL.

While I can't for the life of me figure out why you'd want to do this, it
can be done in one of 3 ways that I can think of offhand:

1. Frameset. The URL will always be the URL of the Frameset itself, not any
of the frames.
2. Use a single page with the default file name is used for all pages
visited. Not good performance-wise.
3. Write a custom HttpHandler that handles all HTTP requests, and passes off
the Request to the appropriate page for processing.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
What You Seek Is What You Get.
 
P

Patrice

I belive you could just prevent caching so that those pages are not taken
into account by the history...

You could also implement something so that it doens't cause a problme if
they try to access to a page out of the expected sequence (it this for a
wizard like UI ?).

Patrice

--
 
M

Mustufa Baig

How can I prevent Pages from caching? I don't want to use Response.Expire=0
because its now old method.

Thanx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,233
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top