I would like to type /blog in my url and have it go to my locally hosted WordPress page at http://localhost/wordpress

I modified my host file to redirect blog to the localhost. Now apache display the 'It works!' page. But I need it to redirect to http://localhost/wordpress

What is the best way to do this?

link|improve this question
feedback

1 Answer

While simply changing the documentroot for your website to the wordpress directory would do the trick, it wouldnt redirect to /wordpress like you want.

I'd suggest using a rewrite rule for this in the apache config.

RedirectMatch ^/$ wordpress/

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.