WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] [.htaccess redirect] from older website to new (4 posts)

  1. fldtrace
    Member
    Posted 4 years ago #

    Hello,

    I try to launch a section built in wordpress and I try to redirect the link from older website to this one.

    The older website is built in a very advanced way so I don't have access over the menu links.

    I tried with .htaccess:

    Redirect 301 /index.php?sec=v http://domain.com/section/

    but it does not work. I checked to see if there is a cache system but is not. There is no older .htaccess either.

    The index.php is in root and apparently there is a folder Data where there is a v.php which is included in index. Hope this helps as well.

    Anybody has experience with redirecting dynamic php links?

    Thanks in advance.

  2. Shane G
    Member
    Posted 4 years ago #

    Hi,

    Have a check with this code for the htaccess redirect to new site:

    RewriteEngine on
    RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L]

    Thanks,

    Shane G.

  3. fldtrace
    Member
    Posted 4 years ago #

    Hi Shane, thanks for help.

    That one works. It redirects the entire website to my section.

    I can't figure out why it doesn't want for that specific links.
    And I was supposed to launch today :(

  4. fldtrace
    Member
    Posted 4 years ago #

    The server does not accept .htaccess file so I had to do that in index.

    if($_GET['sec']=="v") {
    
    header ('HTTP/1.1 301 Moved Permanently');
    
    header ('Location: http://www.ragenassociates.com/vases/');
    
    }

Topic Closed

This topic has been closed to new replies.

About this Topic