Wanto 301 Redirect for 30 to 40 URL

Discussion in 'Apache' started by nile1483, Dec 27, 2009.

  1. #1
    Dear friends

    i start to process convert my static website into joomla, all the content add in joomla, before replace my site i want to 301 redirect my html page to New joomla SEF URL, i am new to this, i dont have more knowledge of apache and htaccess if any know about this please let me know

    i am using cpanel linux hosting of hostgator.com

    My requirement is
    I want to redirect my

    old www.domainxyz.com/domain_name_registration.html (static html page)
    new www.domainxyz.com/domain-name.html (joomla SEF page)

    and almost 30 to 40 page like this
     
    Last edited: Dec 27, 2009
    nile1483, Dec 27, 2009 IP
  2. ibg

    ibg Member

    Messages:
    25
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    38
    #2
    You'll have to do it for each URL if the names are different. Edit your .htaccess file and put this for every URL (on a new line):
    redirect 301 /old_page_name.html http://www.domain.com/new_page_name.html
     
    ibg, Dec 31, 2009 IP
  3. Nintendo

    Nintendo ♬ King of da Wackos ♬

    Messages:
    12,890
    Likes Received:
    1,064
    Best Answers:
    0
    Trophy Points:
    430
    #3
    Or

    Options +Indexes
    Options +FollowSymlinks
    RewriteEngine on
    RewriteBase /
    RewriteRule ^domain_name_registration.html$ http://www.domainxyz.com/domain-name.html [R=301,L]

    with a RewriteRule line like that for each URL.
     
    Nintendo, Jan 6, 2010 IP