Results 1 to 14 of 14
  1. #1
    CasinoDefence's Avatar
    CasinoDefence is offline Public Member
    Join Date
    August 2016
    Location
    London
    Posts
    211
    Thanks
    457
    Thanked 151 Times in 94 Posts

    Default Redirect old pages to new?

    Hi

    I have acquired some affiliate sites recently and a couple are in desperate need of a makeover but have a question about redirecting the old pages to new ones.

    So as an example... the current site uses static html pages (.html) where as the new design site which uses WordPress has the standard /pagename/

    So would I set up a 301 permanent redirect on all 170 pages via a .htaccess file?

    h--p://www.testdomain.co.uk/32red.html >>> h--p://www.testdomain.co.uk/32red/
    h--p://www.testdomain.co.uk/coral.html >>> h--p://www.testdomain.co.uk/coral/

    170 redirects would take a lot of time so was wondering if there was a easier way? The site has good Google SERPS so would be shame to lose any of the existing SEO juice!
    Last edited by CasinoDefence; 15 June 2020 at 12:16 am.
    Tom

    ------------------------------

    Game Show Trackers
    : Monopoly Live | Crazy Time

    New Online Casinos

  2. #2
    universal4's Avatar
    universal4 is offline Forum Administrator
    Join Date
    July 2003
    Location
    Courage is being scared to death...and saddling up anyway. John Wayne
    Posts
    33,996
    Thanks
    4,544
    Thanked 9,298 Times in 5,982 Posts

    Default

    Here is an example at stack exchange
    https://stackoverflow.com/questions/...all-html-files

    There are a few threads on that here, I recall one in the last week or so that had an example in also.

    Rick
    Universal4

  3. #3
    ddm
    ddm is offline Former Member
    Join Date
    July 2006
    Posts
    1,118
    Thanks
    418
    Thanked 470 Times in 287 Posts

    Default

    1 way to do this:

    1. store the 170 urls in a csv file, and their desired new destination
    2. edit your 404.php template
    3. make it parse the CSV, and 301 to new url if requested url == one of the urls in your list, otherwise continue as normal.


    no huge overhead like loading a zillion URIs into a .htaccess file

  4. #4
    Juicer's Avatar
    Juicer is offline Public Member
    Join Date
    January 2020
    Posts
    36
    Thanks
    8
    Thanked 24 Times in 10 Posts

    Default

    Would take a whooping 30 mins to do 170 URL redirects using a redirection plugin, is that a lot of time?

  5. The Following User Says Thank You to Juicer For This Useful Post:

    ddm (15 June 2020)

  6. #5
    baldidiot is offline Private Member
    Join Date
    January 2010
    Posts
    5,098
    Thanks
    433
    Thanked 2,333 Times in 1,555 Posts

    Default

    Quote Originally Posted by Juicer View Post
    Would take a whooping 30 mins to do 170 URL redirects using a redirection plugin, is that a lot of time?
    Should be easy enough to do in htaccess but if you'd rather use a redirection plug in it's also pretty simple. Most of the ones I've seen have the option to do a csv upload, no need to add redirects one by one.

    Alternatively some also allow regex redirects as well so you could just do a general .html to / rule.
    onlinegamblingwebsites.com - Formally known as goodbonusguide.

    Gambling Domains: Small clear out of some of the domains we've been hoarding - see the spreadsheet here.

  7. The Following User Says Thank You to baldidiot For This Useful Post:

    ddm (15 June 2020)

  8. #6
    ddm
    ddm is offline Former Member
    Join Date
    July 2006
    Posts
    1,118
    Thanks
    418
    Thanked 470 Times in 287 Posts

    Default

    considerations:
    170 rw rules in htaccess = bad for performance
    regex or a rewrite rule may not be viable b/c these seem to be root pages - might trigger in spots it doesn't need to.

  9. #7
    citizen42's Avatar
    citizen42 is offline Public Member
    Join Date
    September 2017
    Posts
    117
    Thanks
    21
    Thanked 72 Times in 43 Posts

    Default

    If you want to make the redirects, it wouldn't be170 lines in .htaccess, you use one directive for all URLs ending in .html
    The link @universal4 provided explains how.


    Another option to consider.
    I've seen some websites using WordPress and page URLs ending in .php or .html

    Perhaps, you can do the same and avoid redirects.
    If you're using posts for those static pages, you need to use /%postname%.html/ in permalinks and that should do it.

    If you decide to do so, just do a little tests with category, page URLs.

    Quote Originally Posted by CasinoDefence View Post
    Hi

    I have acquired some affiliate sites recently and a couple are in desperate need of a makeover but have a question about redirecting the old pages to new ones.

    So as an example... the current site uses static html pages (.html) where as the new design site which uses WordPress has the standard /pagename/

    So would I set up a 301 permanent redirect on all 170 pages via a .htaccess file?

    h--p://www.testdomain.co.uk/32red.html >>> h--p://www.testdomain.co.uk/32red/
    h--p://www.testdomain.co.uk/coral.html >>> h--p://www.testdomain.co.uk/coral/

    170 redirects would take a lot of time so was wondering if there was a easier way? The site has good Google SERPS so would be shame to lose any of the existing SEO juice!
    affkraft.com → WordPress Themes & Plugins for Sports, Casino and Forex Affiliates
    tablrr.app → Centralized Listing Management and Automated Sync for Affiliate Marketers

  10. #8
    universal4's Avatar
    universal4 is offline Forum Administrator
    Join Date
    July 2003
    Location
    Courage is being scared to death...and saddling up anyway. John Wayne
    Posts
    33,996
    Thanks
    4,544
    Thanked 9,298 Times in 5,982 Posts

    Default

    Why use a plugin to do what htaccess or web.config or even manually in cpanel will do?

    Those 3 methods are directives processed by the server at the beginning of any page calls. Plugin redirects are processed as the site is loading and require additional database calls, thus making the plugin type slower.

    If you are redirecting ALL pages.html pages to /pages/ one thing to remember to consider is if you had visit links that were also .html

    At that point I think I would consider changing those all to visit/pages.php otherwise they could get trapped into most of the above suggestions.

    There are a number of plugins you can use to help with search and replace if your visit links are hard coded into pages, but I have used these methods and plan on doing so in the coming weeks with a few sites that will be changed over from html to wordpress.

    Rick
    Universal4

  11. The Following User Says Thank You to universal4 For This Useful Post:

    Cash Bonus (15 June 2020)

  12. #9
    Toomek is offline Private Member
    Join Date
    July 2020
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Completely agree. Don't use plugins for whatever you can do by yourself

  13. #10
    Jumpmanbingosites.uk is offline Public Member
    Join Date
    August 2020
    Posts
    5
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    Read plenty of guidea and articles and be careful how to proceed.

  14. #11
    saicharan's Avatar
    saicharan is offline Brand New Member
    Join Date
    August 2020
    Location
    India
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    can you explain in detail how to redirect in word press?

  15. #12
    universal4's Avatar
    universal4 is offline Forum Administrator
    Join Date
    July 2003
    Location
    Courage is being scared to death...and saddling up anyway. John Wayne
    Posts
    33,996
    Thanks
    4,544
    Thanked 9,298 Times in 5,982 Posts

    Default

    As others have stated above, in most cases for most webmasters, they will want to do the redirects in htaccess.

    If you absolutely have to use a plugin, there are a number of them available, some write to the htaccess, and if so manually adding them is better rather then adding yet another plugin.

    If you look at the stackoverflow example I linked to above, and your wordpress pages followed the same naming convention, the majority would be dome with one rule.

    Rick
    Universal4

  16. #13
    gil.langelaan's Avatar
    gil.langelaan is offline Private Member
    Join Date
    July 2018
    Location
    Johannesburg
    Posts
    966
    Thanks
    110
    Thanked 308 Times in 244 Posts

    Default

    You should use htaccess rule to 301 all .html pages to new pages.

  17. #14
    Jason.F is offline Brand New Member
    Join Date
    July 2020
    Location
    UK
    Posts
    8
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Default

    301 - plugins prettylinks, 404 to home page

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •