I have a url that reads index.php?dir=10-webtraffic/ would like it to be category/10-webtraffic/ Then I have links like this downloads/10-webtraffic/Effectively-Using-Overture-Yahoo-To-Get-Website-Visitors.txt I would like to replace the "-" with "_" Does this last part work better for search engine friendly urls Thank you in advance
Thanks for the try is didnt do anything. I have also decided not to change the hyphens to underscores. Just looking to change the index.php?dir= to category
knew it wasnt just me that one didnt work either This is being applied to the 3rd link in my signature didnt work
RewriteEngine on RewriteRule ^category/(.*)$ index.php?dir=$1 Code (markup): In which folder are you saving this?
its being put in the public_html I will hire someone to sort this out. I think I have some php code that is conflicting or changing it.
Options +FollowSymLinks +Indexes RewriteEngine on RewriteBase / RewriteRule ^category/([^.]+)/$ index.php?dir=$1 [L] - are better than _ SEO wise.
Nintendo thank you for your try. I am looking for someone to look in to the code as it Htaccess.php which I think is keeping the rewrites from working. I could be wrong. Thank you also for the "_" "-" answer found out that the "_" actually is ignored by the engines basically removing them and combining the words. where as the "-" is recognized as stop so the engine sees all the words as keywords.
your files name should be .htaccess no htaccess.php or as far as i know that is how it should be, it's that way on my sites. I am not on my normal pc that I use for my websites do I dont have any of my files but tomorrow morning if you havnt figured this out I can send you a file to use. (i don't remember the code off the top of my head)
I know but in this file it is rewriting things I will supply a snippet of it to show this. So this file is making the htaccess rewrites not work