Plesk – Redirecting a URL
by Alx on Feb.10, 2009, under Work
Being most familiarized with Cpanel I always thought this task would be simple in Plesk as well, at least from what I’ve read in some blogs and forums Plesk seamed awesome and simple enough to get a website up and running in no time.
I would be so lucky, at least in the hosting provider I am working with no simple click and save options in order to get a redirection done. After a few e-mails exchange with the provider in order for him to show me if this could be done by any other method, they pretty said it could by did not provide any help or example what so ever. (Probably my question should be issued in a command voice in order for them to get my point).
Well no problem just create a .htaccess file under you public root and you will be fine.
In my case I want to redirect all traffic coming in the main URL to a directory under the public root directory (usually public_html or httpdocs) so in the newly created file just put in the following code:
RewriteEngine on
RewriteCond %{HTTP_HOST} ^.*$
# Rules for MY_SITE
RewriteRule ^/?$ http://www.mydomain.com/my_directory [R=302,L]
Now let me just try it on a browser to make sure, and I’m all set.
Time to get back to work..
April 14th, 2009 on 07:59
nice theme. Download from wordpress.org? Can you tell me download link.Thank you.
June 15th, 2009 on 08:30
Great post! I’ll subscribe right now wth my feedreader software!
June 16th, 2009 on 17:28
How soon will you update your blog? I’m interested in reading some more information on this issue.