Results 1 to 5 of 5
  1. #1
    Join Date
    Mar 2013
    Location
    Sydney, Australia
    Posts
    140
    Plugin Contributions
    0

    Default Redirect 302 picked up

    I used a tool http://www.redirect-checker.org/index.php to check the redirect that's happening on my site .
    I was surprised to see it has a 302, I would like a 301.
    If I redirect it from cpanel it says its in a redirect loop too many redirects.
    I turned off the redirect from cpanel. I recently turned on the ssl. (see my other post https://www.zen-cart.com/showthread....ant-logging-in )

    How can I make it a 301?

    This is the read out from the tool:

    http://www.example.com.au
    302 Found
    https://example.com.au/
    200 OK

    Problems found:

    You use a 302 redirect. This means, that the actually content is temporary not reachable and will come back soon.
    To use a 302 redirection for generally moved pages is a bad idea.
    Search engine bot might not follow it or handle it as temporary.
    or SEO this is also a bad idea, because no link juice will be transferred to the linked page.
    HTTP Headers

    >>> http://www.example.com.au

    > --------------------------------------------
    > 302 Found
    > --------------------------------------------

    Status: 302 Found
    Code: 302
    Server: nginx
    Date: Wed, 27 Jan 2016 04:56:05 GMT
    Content-Type: text/html; charset=iso-8859-1
    Content-Length: 213
    Connection: close
    Location: https://example.com.au/




    >>> https://example.com.au/

    > --------------------------------------------
    > 200 OK

  2. #2
    Join Date
    Mar 2013
    Location
    Sydney, Australia
    Posts
    140
    Plugin Contributions
    0

    Default Re: Redirect 302 picked up

    I opened up the ht access file and added R=301 and it seems to have fixed it.
    I hope that's ok. If anyone knows better let me know.

    See new tool output:
    http://example.com.au
    301 Moved Permanently
    https://example.com.au/
    200 OK

    HTTP Headers

    >>> http://example.com.au

    > --------------------------------------------
    > 301 Moved Permanently
    > --------------------------------------------

    Status: 301 Moved Permanently
    Code: 301
    Server: nginx
    Date: Wed, 27 Jan 2016 05:46:58 GMT
    Content-Type: text/html; charset=iso-8859-1
    Content-Length: 237
    Connection: close
    Location: https://example.com.au/




    >>> https://example.com.au/

    > --------------------------------------------
    > 200 OK
    > --------------------------------------------

    Status: 200 OK
    Code: 200
    Date: Wed, 27 Jan 2016 05:47:00 GMT
    Server: Apache/2.2.26 (Unix) mod_ssl/2.2.26 OpenSSL/1.0.1e-fips mod_bwlimited/1.4 mod_perl/2.0.6 Perl/v5.10.1
    X-Powered-By: PHP/5.3.29
    Expires: Thu, 19 Nov 1981 08:52:00 GMT
    Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
    Pragma: no-cache
    Set-Cookie: zenid=uu6sftfrvr6hfb866243hm8ej0; path=/; domain=.www.example.com.au; HttpOnly
    Content-Length: 47929
    Connection: close
    Content-Type: text/html; charset=utf-8

  3. #3
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Redirect 302 picked up

    Quote Originally Posted by Annie_zaz View Post
    I used a tool http://www.redirect-checker.org/index.php to check the redirect that's happening on my site .
    I was surprised to see it has a 302, I would like a 301.
    302's are far more commonly used than 301's.

    Quote Originally Posted by Annie_zaz View Post
    If I redirect it from cpanel it says its in a redirect loop too many redirects.
    I turned off the redirect from cpanel.
    .
    FYI, the 'cpanel redirect' is a bit misleading in that cPanel doesn't actually do the redirecting (as many seem to think). What the cPanel redirect *tool* does is to create an entry into the .htaccess file. I feel this is important to know because although the cPanel tool tends to make this a bit of a 'no brainer', it can cause a problem if you already have *other* redirect rules in place in the .htaccess file. The Cpanel Tool simply adds rules to the end of the file, but quite often you will be wanting this rule to be one of the 1st ones in the file (as they are acted upon in the order they are written) and this is quite probably the cause of your redirect loop - the .htaccess may well have had the correct rules, but in the wrong order.


    Quote Originally Posted by Annie_zaz View Post
    How can I make it a 301?.
    I see you have already discovered how.

    Quote Originally Posted by Annie_zaz View Post

    This is the read out from the tool:

    http://www.example.com.au
    302 Found
    https://example.com.au/
    200 OK

    Problems found:
    You use a 302 redirect.
    Hmmm, personally I wouldn't consider this to be a 'problem' in that it is perfectly normal - in fact it is actually *too* normal in that many people will set up a perfectly good working and indexable ZenCart with zero redirects involved, and then they'll read something about 'SEO' and promptly go ahead and add a zillion rewrites and redirects to make a 'pretty URL' (via a SEO module). This is all well and good until at some future date the site gets moved/reorganised and the redirects are then actually needed (to a point), and you end up with an overly complex .htaccess file trying to keep everything where it all belongs.


    Quote Originally Posted by Annie_zaz View Post
    You use a 302 redirect. This means, that the actually content is temporary not reachable and will come back soon.
    To use a 302 redirection for generally moved pages is a bad idea.
    Search engine bot might not follow it or handle it as temporary.
    Matt Cutts (Google SEO guru) actually has a fair bit to say about the 301's vs the 302's - and the bottom line (the way I understand it) is that Google basically treats them equally.


    Quote Originally Posted by Annie_zaz View Post
    or SEO this is also a bad idea, because no link juice will be transferred to the linked page.
    I've been arguing this case for years. The 'SEO experts' don't tend to agree though.

    You know what *I* do these days if/when a page is moved? Nothing. That's what. I just "let them go" and have the server provide the oft dreaded 'page not found' error to both people and bots. It is then only a matter of time (days, perhaps a week or two) before the SE's drop the links to the original page (now gone) and will have re-indexed it again (in its new location). OK, so things may be a bit 'messy' during this period, but with no rewrites or redirects in place I avoid all possibility of setting up infinite loops and/or other similar issues where redirected URLs need to be redirected.

    For those that still think I'm anti-SEO I wish to stress that this is NOT true - it is the *needless* redirects/rewrites that are often used to obtain 'pretty URL's that I object to, not the 'Friendly' URL's themselves.

    Anyway, back to your question/problem, what you have done, as long as it achieves your aims, has been done correctly, it is just that in my view/experience it will more often lead to bigger headaches in the longer term than the short term headaches that you are avoiding by using the redirect in the 1st place.

    As for the SE's and effects - for the contents of any given page on any given site the rankings will end up being exactly the same at the end of the day (with perhaps the site with no redirects ranking slightly higher). The *location* of the page/site isn't a ranking factor (it *used* to be many years ago) so on this basis letting a moved page 'disappear' (404 error) and then 're-appear' at a different URL comes with a short time 'cost' (no one likes 404 errors) but long term benefits (No penalties for the redirect), with the added benefit of a simpler .htaccess file, perhaps only containing the things it was originally designed for (Access control) - That's how it got its name BTW.

    Bottom line - Avoid URL redirects/rewrites at all costs unless there an an absolute and genuine need for it.
    Good examples would be to redirect to/from 'domainname.com' to 'www.domainname.com' (Else the SE's will consider these as two different sites - causing the rankings to be split/divided. Another good use is if you use print media (where the customers are half expected to type in the URL rather than having a link to click) - In this case, a redirect from (say) www.domain.com/contact to the 'real' page @ www.domain.com/index.php?main_page=contact_us just makes perfectly good sense.
    I can't think of any other *good* reason to use a URL redirect.

    Cheers
    RodG

  4. #4
    Join Date
    Mar 2013
    Location
    Sydney, Australia
    Posts
    140
    Plugin Contributions
    0

    Default Re: Redirect 302 picked up

    Quote Originally Posted by RodG View Post
    302's are far more commonly used than 301's.



    FYI, the 'cpanel redirect' is a bit misleading in that cPanel doesn't actually do the redirecting (as many seem to think). What the cPanel redirect *tool* does is to create an entry into the .htaccess file. I feel this is important to know because although the cPanel tool tends to make this a bit of a 'no brainer', it can cause a problem if you already have *other* redirect rules in place in the .htaccess file. The Cpanel Tool simply adds rules to the end of the file, but quite often you will be wanting this rule to be one of the 1st ones in the file (as they are acted upon in the order they are written) and this is quite probably the cause of your redirect loop - the .htaccess may well have had the correct rules, but in the wrong order.




    I see you have already discovered how.



    Hmmm, personally I wouldn't consider this to be a 'problem' in that it is perfectly normal - in fact it is actually *too* normal in that many people will set up a perfectly good working and indexable ZenCart with zero redirects involved, and then they'll read something about 'SEO' and promptly go ahead and add a zillion rewrites and redirects to make a 'pretty URL' (via a SEO module). This is all well and good until at some future date the site gets moved/reorganised and the redirects are then actually needed (to a point), and you end up with an overly complex .htaccess file trying to keep everything where it all belongs.




    Matt Cutts (Google SEO guru) actually has a fair bit to say about the 301's vs the 302's - and the bottom line (the way I understand it) is that Google basically treats them equally.




    I've been arguing this case for years. The 'SEO experts' don't tend to agree though.

    You know what *I* do these days if/when a page is moved? Nothing. That's what. I just "let them go" and have the server provide the oft dreaded 'page not found' error to both people and bots. It is then only a matter of time (days, perhaps a week or two) before the SE's drop the links to the original page (now gone) and will have re-indexed it again (in its new location). OK, so things may be a bit 'messy' during this period, but with no rewrites or redirects in place I avoid all possibility of setting up infinite loops and/or other similar issues where redirected URLs need to be redirected.

    For those that still think I'm anti-SEO I wish to stress that this is NOT true - it is the *needless* redirects/rewrites that are often used to obtain 'pretty URL's that I object to, not the 'Friendly' URL's themselves.

    Anyway, back to your question/problem, what you have done, as long as it achieves your aims, has been done correctly, it is just that in my view/experience it will more often lead to bigger headaches in the longer term than the short term headaches that you are avoiding by using the redirect in the 1st place.

    As for the SE's and effects - for the contents of any given page on any given site the rankings will end up being exactly the same at the end of the day (with perhaps the site with no redirects ranking slightly higher). The *location* of the page/site isn't a ranking factor (it *used* to be many years ago) so on this basis letting a moved page 'disappear' (404 error) and then 're-appear' at a different URL comes with a short time 'cost' (no one likes 404 errors) but long term benefits (No penalties for the redirect), with the added benefit of a simpler .htaccess file, perhaps only containing the things it was originally designed for (Access control) - That's how it got its name BTW.

    Bottom line - Avoid URL redirects/rewrites at all costs unless there an an absolute and genuine need for it.
    Good examples would be to redirect to/from 'domainname.com' to 'www.domainname.com' (Else the SE's will consider these as two different sites - causing the rankings to be split/divided. Another good use is if you use print media (where the customers are half expected to type in the URL rather than having a link to click) - In this case, a redirect from (say) www.domain.com/contact to the 'real' page @ www.domain.com/index.php?main_page=contact_us just makes perfectly good sense.
    I can't think of any other *good* reason to use a URL redirect.

    Cheers
    RodG
    Thanks Rod G,
    The cpanel redirect is bodgy lol. I did the 301 redirect just be safe and it came back with a No Problem reported response. But I did it myself in the ht access file.

  5. #5
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    6,167
    Plugin Contributions
    7

    Default Re: Redirect 302 picked up

    Quote Originally Posted by Annie_zaz View Post
    Thanks Rod G,
    The cpanel redirect is bodgy lol.
    That basically what I wrote - however what you put into 5 words took me 5000. LOL

    Cheers
    RodG

 

 

Similar Threads

  1. v139h redirect 302
    By lruskauff in forum General Questions
    Replies: 0
    Last Post: 2 Jan 2014, 06:04 AM
  2. 302 redirect with languages vs search engines
    By xordox in forum Bug Reports
    Replies: 1
    Last Post: 1 Nov 2008, 01:34 PM
  3. How to Get Rid of a 302 Redirect
    By Frank0 in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 13 Jul 2008, 08:19 PM
  4. 302 Redirect error with worldpay mod
    By crazycucumber in forum General Questions
    Replies: 1
    Last Post: 23 May 2007, 01:27 PM

Posting Permissions

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