Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Feb 2007
    Posts
    24
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Directing to a website via alternate url...

    I hope someone can advise me with this issue. I want to see if some of my print advertising is successfully directing people to my website. I thought a good way to do this would be to use a web address specific to the publication e.g.

    www.mywebsite.com/magazine.html

    My question is firstly is this the best way to do this and if so do I create a redirect page called magazine.html or do I just make a copy of my index.html page called magazine.html?

    Any tips would be great, also is there a way to make sure people who type incorrect names get to the desired page ie

    www.mywebsite.com/Magazine.html
    www.mywebsite.com/magazine.htm

    etc...?

    Many thanks

  • #2
    Master Coder mlseim's Avatar
    Join Date
    Jun 2003
    Location
    Cottage Grove, Minnesota
    Posts
    9,369
    Thanks
    8
    Thanked 1,075 Times in 1,066 Posts
    First off, I would create a directory called "magazine" and in that
    directory, you would have an "index.php" file. That way, they would
    only be typing "www.mywebsite.com/magazine" (index.php is default).

    index.php would be a redirect PHP script to your "real" page.

    PHP Code:
    <?php
    header 
    ("location: http://www.mywebsite.com");
    ?>
    The case-sensitive issue, not sure if you can do anything about that.
    There might be an .htaccess thing you could look into (not sure about this).

  • #3
    New Coder
    Join Date
    Feb 2007
    Posts
    24
    Thanks
    1
    Thanked 0 Times in 0 Posts
    that's great thanks, i had thought that once i had posted my question. Good to have reassurance though


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •