December 25th, 2012, 11:08 PM
i want to redirection script for
websitename/abc/ to websitename/
my website saved in abc folder. first i set the permenent redirection in Cpanel from websitename to abc folder. but i want to display only website name..don't want to display folder.
Now, i am using this code.. but not working...
RewriteRule ^abc/$ / [R=302]
Please suggest that..
December 26th, 2012, 01:26 AM
There may be a better way of doing this. You mention CPanel so I assume you're on shared hosting. Do you have shell access?
December 26th, 2012, 01:41 AM
i am using Godaddy cpanel.... I dont have access reg shell... i am not using shared server. that cpanel only for single domain...
Originally Posted by requinix
December 26th, 2012, 03:02 AM
Eh, I'll skip the targeted questions.
Unless you have other rewriting rules, and if so depending what they are, this may be all you need.
# send everything through /abc/
RewriteRule ^/?(.*) abc/$1 [L]