WordPress.org

Forums

Redirecting One Site to Another (3 posts)

  1. LavishDhand
    Member
    Posted 2 years ago #

    Hello!

    I am here seeking some help in redirecting an entire old static html site to a new wordpress site page by page. Domain names and servers are separate. We will close old site once new is indexed by serach engines.

    Eg; http://www.oldwebsite.com/about to http://www.newwebsite.com/about
    Oldwebsite = HTML static, Newwebsite = WordPress.

    I have tried below in my ataccess but it's not working. Both servers are linux with apache

    Redirect 301 /about http://www.newwebsite.com/about

  2. LavishDhand
    Member
    Posted 2 years ago #

    I have googled for hours with no success, I think the problem is that my old sites urls have no extentions.

    Is theres a htaccess code that can redirect files with extentions, examples like:

    http://www.oldwebsite.com/page1 to http://www.newwebsite.com/page1
    http://www.oldwebsite.com/folder1/page1 to http://www.newwebsite.com/page2

    and so on

    Thanks

  3. LavishDhand
    Member
    Posted 2 years ago #

    Following worked for me

    RewriteRule ^/?pagename(.*)$ http://www.newwebsite.com/pagename [L,R=301]

    Thanks

Topic Closed

This topic has been closed to new replies.

About this Topic