I've just installed this new script for a search engine I'm getting finished up. Whenever you go to www.MYDOMAIN.com, it redirects you automatically to www.MYDOMAIN.com/search/searchscript.php My question is, how can I make the address bar at the top say just www.MYDOMAIN.com when the homepage is accessed? I only want it to say that on the homepage, if it says that on every page, then nobody will be able to send links to search results/games/etc.. to others. Is this possible?
The way I would do it (And the way I do stuff isn't pretty, but it works): Edit the index.htm/php/html/asp/whatever-extension file with a server-side script to open the /search/searchscript.php file and echo it to the user. For example in php: <?php $page=file_get_contents("http://yourdomain.com/search/searchscript.php); echo $page; ?> You'll want to put some instructions in there for security. (For example http://yourdomain.com/?page=/etc/passwd or something)
I'd go for gopher292 approach. It's clean and transparent to the user. The only problem would be the relative links if any in the fetched page. Another option would be to make the top page a single frame (html <frameset> tag). But this will require all links on the page to supply a target="_top" attribute to break out of the frame