View Full Version : Changing /redir/?q= --> /redir?q=

10-31-2007, 06:53 PM
i have a folder named redir with this code inside it:

header("Location: {$q}")

the link would be site.com/redir/index.php?q=http://redirectedsite.com

i want to change that to site.com/redir?q=http://redirectedsite.com

thanks in advance.

10-31-2007, 08:09 PM
Assuming you are on a Unix-based system, create a file called .htaccess that contains the following text and place it in your root folder:

RewriteEngine on
RewriteBase /
RewriteRule ^redir$ redir/index.php [QSA,NC]

11-01-2007, 06:23 PM
it worked!

thanks! :thumbsup:

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum