I am having problems converting my URLS.. From: www.scrimsnow.com/index.php To: www.scrimsnow.com/index/ Below is what I have in my .htaccess file. # -Manipulate URLs- Options +Indexes Options +FollowSymlinks RewriteEngine on RewriteBase / RewriteRule ^index/$ index.php [L] RewriteRule ^myaccount/$ myaccount.php [L] RewriteRule ^console/$ console.php [L] RewriteRule ^about_us/$ about.php [L] RewriteRule ^logout/$ logout.php [L] RewriteRule ^login/$ login.php [L] RewriteRule ^privacy/$ privacy.php [L] RewriteRule ^site_map/$ sitemap.php [L] RewriteRule ^staff/$ staff.php [L] RewriteRule ^sponsors/$ sponsors.php [L] RewriteRule ^ucp/$ ucp.php [L] # -Force non-www URLs- RewriteCond %{HTTP_HOST} ^www\.scrimsnow\.com$ [NC] RewriteRule ^(.*)$ http://scrimsnow.com/$1 [R=301,L] PHP:
Options +Indexes Options +FollowSymlinks RewriteEngine on RewriteBase / RewriteRule ^([^.]+)/$ $1.php [L]
Try it with # -Force non-www URLs- RewriteCond %{HTTP_HOST} ^www\.scrimsnow\.com$ [NC] RewriteRule ^(.*)$ http://scrimsnow.com/$1 [R=301,L] first. The redirect might be messing it up. If that doesn't fix it, try only having Options +Indexes Options +FollowSymlinks RewriteEngine on RewriteBase / RewriteRule ^wacko.html$ index.php [L] in the .htaccess file and see if scrimsnow.com/wacko.html works. That'll tell you if you can change the URLs of files.
Just to make sure you want people accessing xy.com/index/ to get xy.com/index.php transparently right? Try this: RewriteEngine on RewriteBase / RewriteRule ^index/$ index.php?$1 [R,NC,L] Code (markup):
that didn't work, Idk why this isn't working.. Do I have to have any other attributes? Do my pages before have to be like index.php?id=index?
I know it doesn't help your current problem but as Nintendo said, you will need to move the "Force non-www" lines above the other rules. If your current rules were working, it would first rewrite /index/ to /index.php, then redirect that request to the non-www domain. It would send a request for www.scrimsnow.com/index/ to scrimsnow.com/index.php, which isn't what you want. But because of the other issue, currently the "force non-www" appears to be working fine. All I can suggest is 'prodding' the code till it works. Have you tried it without the trailing slash? What about without forcing the end with $? With a bit of trial and error, you may be able to determine where the problem is - for some reason the rewriterules are not being applied, and you would think that would be because the pattern does not match the request. But the code you posted is correct and should work, so I doubt anyone will be able to give you a magic solution, unfortunately.