Results 1 to 3 of 3
  1. #1

    Dynamic URL to Dynamic URL redirect with htaccess

    Hey everyone,

    due to switching of hosts messing up the hierarchies of some pages, had to switch these PHP pages

    domain.com/index.php?id="tonsofpages"

    to

    domain.com/newindex.php?id="tonsofpages"

    is this possible, and if so, how can i do this with htaccess?

    thanks so much for any help!

  2. #2
    Join Date
    Feb 2005
    Location
    Australia
    Posts
    5,842
    Code:
    Redirect permanent /index.php /newindex.php
    (the query string should be handled automatically).
    Chris

    "Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them." - Laurence J. Peter

  3. #3
    Join Date
    May 2009
    Posts
    766
    And speaking of your query string...wtf man?

    If a quote character is literally part of the value, it should be URI-escaped (http://php.net/manual/en/function.urlencode.php)

    If you're using it for something funky like field delimiting...cut it out! URI encoding is designed to handle that. This isn't a CSV file!

Similar Threads

  1. .htaccess redirect for dynamic pages
    By QiQ - QiQ in forum Programming Discussion
    Replies: 2
    Last Post: 05-20-2009, 06:58 PM
  2. Please help redirect dynamic url with htaccess
    By daniellosada in forum SEO / SEM Discussions
    Replies: 2
    Last Post: 04-10-2009, 02:09 PM
  3. 301 redirect dynamic to dynamic
    By techguru in forum Programming Discussion
    Replies: 1
    Last Post: 01-20-2009, 09:43 PM
  4. htaccess redirect dynamic URL to dynamic URL
    By Badie in forum Programming Discussion
    Replies: 16
    Last Post: 01-17-2008, 02:01 AM
  5. Permanent redirect of dynamic links
    By Adam W in forum Hosting Security and Technology
    Replies: 3
    Last Post: 06-28-2006, 10:19 PM

Posting Permissions

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