How can I change the name of a folder. EG: when I type into the address bar - www.mydomain.com/verylongfoldername, it actually goes to www.mydomain.com/shortfoldername ? I dont want to physically change the folder name (due to reasons I wont go into here). I guess .htaccess would be the best way to do this. I suppose Im after a way to cloak the url.
Yes, I looked at that link, and it shows how to rewrite php page to htm etc... and I tried to hash the script so it woudl rewrite "/something" to "/somethingelse" and couldnt for the life of me get it working! I cant imagine it being that hard to do - but I cant do it. I though that the server might be caching my .htaccess file or something.
Can you see why the below wont work (rewriting a folder 'something' to 'somethingelse')?
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^something$ $1somethingelse [NC]
Bear in mind that $1 is only if you're taking a variable from the left and putting it on the right
In example
^([/0-9/])$ index?id=$1
would take the number and throw it over to the ID.
Code may be off cause it's 2:00 AM but you get the idea, I hope.
Bookmarks