I want my site address bar not to change its address when I go to subpages, it should show my index.html
, even though I enter tosub pages.
Like if I open www.xyz.com
and I navigate to any page it should still show www.xyz.com
.
I heard this can be done with .htaccess
is it possible?
You really should think about why you want it, because this way of working has a couple of drawbacks with it:
- Users can't see they are on a different page
- Users can't bookmark your pages for fast access
- Users can't share links to eachother
- Search Engines may have trouble spidering your side
But basically, there are two main ways to do this:
- Use frames. Put the page into a frame, and have all the links stay in this frame.
- Use Javascript. Have each page "load" into the current page, using AJAX.