Results 1 to 6 of 6
  1. #1
    Join Date
    Aug 2006
    Location
    Derbyshire, UK
    Posts
    114

    Lightbulb Myspace style redirection?

    Hi there,

    Thought i would query you guys to see if anyone had heard of this - im looking to implement redirection similar to myspace into a web project, for example when the visitor goes to www.mydomain.com/user1245 it would redirect them to say www.domain.com/user.php?user1245...

    Has anybody seen methods for doing something like this before? Ive tried googling for it but putting myspace in any search seems to get you tons of irrelevant results.

    If anybody could help if would be most appreciated

    Cheers

    Carl

  2. #2
    Join Date
    Jan 2005
    Location
    Nederland
    Posts
    93
    You would need some kind of rewrite module for this:

    For Linux: http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html

    For Windows: http://www.isapirewrite.com/

  3. #3
    Join Date
    Aug 2006
    Location
    Derbyshire, UK
    Posts
    114
    Hi,

    Thanks for your input - i will look into the provided link, ill post back if i determine how to do it!

    Cheers

    Carl

  4. #4
    Join Date
    Aug 2006
    Location
    Costa Blanca, Spain
    Posts
    144
    *nix:


    Code:
     
    Options FollowSymLinks
    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^user/(.*)$ http://www.domain1.com/user.php?user=$1 [L,NC]

    Will take www.domain.com/user/12345
    and redirect to
    www.domain1.com/user.php?user=12345
    James Bone, citruszebra
    citruszebra.cz // 03333 404 100 // cz-at-citruszebra.cz

    Any views are my own and not of any company I may represent.

  5. #5
    Join Date
    Aug 2006
    Location
    Derbyshire, UK
    Posts
    114
    Thats Very kind of you James, had not managed to work it out myself so far.

    Really greatful, thanks!

    Carl

  6. #6
    Join Date
    Aug 2006
    Location
    Costa Blanca, Spain
    Posts
    144
    No problems, glad to be of some use!
    James Bone, citruszebra
    citruszebra.cz // 03333 404 100 // cz-at-citruszebra.cz

    Any views are my own and not of any company I may represent.

Posting Permissions

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