Vortech
09-02-2001, 12:47 AM
Does any one know of a simple way to go from like domian.com to domain.com/folder/filename.cgi.. I looked around hotscripts not much there or was to much for some thing this simple.. It's easy in windows/asp but can't find some thing simple for linux based..
Just some thing very very simple php would work great...
Thanks..
Chicken
09-02-2001, 12:59 AM
throw up an .htaccess file:
Redirect / /folder/filename.cgi
-should do the trick. If not, try:
Redirect / http://domain.com/folder/filename.cgi
Vortech
09-02-2001, 01:13 AM
Well the first one seems to be getting as Internal Server Error
and the next one makes the URL look like
domain.com/folder/filename.cgifolder/filename.cgifolder/filename.cgifolder/filename.cgifolder/filename.cgifolder/filename.cgifolder/filename.cgi,,,, and so on till it can't do any more... Is there a easy way to do this in a php index.php file.. I think that would be the best way for me any way.. ;)
I am an NT tech planing with a site on unix so you know how this can go..LOL
Chicken
09-02-2001, 01:42 AM
Hmmm, I may have screwed that up, what about:
Redirect index.html http://domain.com/folder/filename.cgi
Also, I've heard that this works but I don't know what it si really, but worth a try:
XBitHack on
Redirect index.html http://domain.com/folder/filename.cgi
Trial and error, spit and gum, that's how I do it :D
Try this:
Redirect /index.html http://domain.com/folder/filename.cgi
with the slash before index.html and this will work for you.
eva2000
09-02-2001, 01:58 AM
or a index.php file with
<?
header("Location:http://domain.com/folder/filename.cgi");
?>
qslack
09-02-2001, 02:22 AM
If the redirect is gonna be permanent, you should use RedirectPermanent instead of Redirect in your Apache config. That way the browsers will remember the redirect and update bookmarks, etc. accordingly.