Changing Text In URL Field

Discussion in 'PHP' started by Seoke, Nov 6, 2007.

  1. #1
    I'm working on setting up my webcomic, and I have it so that the index.php redirects using this code:

    
    <?php
    header('Location: http://www.gamanime.com/gamanime.cgi') ;
    ?>
    
    Code (markup):
    Now how do I get it so that when it goes to that site instead of displaying http://www.gamanime.com/gamanime.cgi in it, it just displays http://www.gamanime.com

    Is this possible? Any help would be greatly appreciated ^_^
     
    Seoke, Nov 6, 2007 IP
  2. xemiterx

    xemiterx Peon

    Messages:
    62
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I believe you should use htaccess to set your index page to gamanime.cgi so a visit to http://www.gamanime.com will show the gamanime.cgi file without changing the address bar.

    .htaccess file:
     
    xemiterx, Nov 6, 2007 IP
  3. garbageman

    garbageman Peon

    Messages:
    29
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Just a note on that, htaccess will apply to subdirectories, so your whole site will have to use "gamanime.cgi" as a standard index file.
    Also, that overrides the normal index options.
    I would suggest
    DirectoryIndex index.html gamanime.cgi index.<etc.>
    Code (markup):
     
    garbageman, Nov 6, 2007 IP