Domain redirect

Good morning - I apologize if this has already be covered in the forum. Not having any luck searching past posts.

I want to have www.example.com/ resolve to www.example.com/blog/. What is the best way of doing this? I see that under “Manage Domains” in panel.dreamhost.com there is a " Redirected (A redirect to another site; browser URL changes.)" but I am not sure if this is what I am looking for.

Appreciate the guidance - David

Create a file called .htaccess

Put just one line in it

<?php header('Location: http://www.example.com/blog/.'); ?>

upload .htacess to http://www.example.com

That’s what i would do. fast and easy


http://theMezz.com

Go to DH panel --> Domains --> Manage Domains --> Web Hosting --> Edit, change the root directory of your domain to http://www.example.com/blog/

Save the changes and it is done. :slight_smile:

$50 off and 3 free domains with code: [color=#CC0000]DH3[/color] Sign Up NOW or More Codes Here

The only caveat with changing the root directory is that you’ll have to check the config files to make sure they don’t point to http://mydomain.com/blog, but just http://mydomain.com now that the root directory has changed.

-Scott

theMezz, patricktan & sdayman

Thank you for your responses.