Kyle93816
asked on
Using mod_rewrite when site is on subdomain
Hi, I'm trying to use mod_rewrite to produce clean URI's, but the page won't load after I make the required changes to the .htaccess file.
I'm setting up a photo site on a subdomain of my main site, and I think I may need a different value for RewriteBase (instead of a subfolder) because of that. Hoping someone can point me in the right direction. Thanks!
Code:
RewriteEngine on
RewriteBase /subfolder/
RewriteRule ^(.*)/(.*)?/?$ index.php?a=$1&i=$2 [QSA]
RewriteRule ^(.*)?/?$ index.php?a=$1 [QSA]
I'm setting up a photo site on a subdomain of my main site, and I think I may need a different value for RewriteBase (instead of a subfolder) because of that. Hoping someone can point me in the right direction. Thanks!
Code:
RewriteEngine on
RewriteBase /subfolder/
RewriteRule ^(.*)/(.*)?/?$ index.php?a=$1&i=$2 [QSA]
RewriteRule ^(.*)?/?$ index.php?a=$1 [QSA]
did you miss the RewriteCond ?
ASKER
I'm not sure. I don't know what that means.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.