• Resolved Rik0399

    (@rik0399)


    Hi John,

    Query if I may …

    When a SE hits a page/post URL its shown as a 404?

    But, when I do the following it works :

    /dr-david-jacks-skincare/.*

    /dr-david-jacks-skincare/

    Do you have any idea why this is as clearly, the url was/is correct?

    The problem is it’s having to perform twice to get to the same url?

    Appriciated πŸ™‚

Viewing 13 replies - 1 through 13 (of 13 total)
  • Plugin Author John Godley

    (@johnny5)

    Can you give an example of a URL that is returning a 404?

    Are those redirects you’ve created?

    Thread Starter Rik0399

    (@rik0399)

    Hi John,

    Thanks for the fast response, appreciated

    Typically yes,:

    SO I get a 404’s for urls like this : /dr-david-jacks-skincare/

    So I have to do this :

    /dr-david-jacks-skincare/.*

    /dr-david-jacks-skincare/

    Which then works but, as you can see, it then has to double the action then it goes to the url

    Hope that makes sense

    Regards

    Plugin Author John Godley

    (@johnny5)

    What do you mean by double the action?

    Thread Starter Rik0399

    (@rik0399)

    Hi John,

    When the url gets a hit it from hacker or SE, it creates a 404 (the url is correct), so I then create a redirect like so :

    /dr-david-jacks-skincare/.*

    /dr-david-jacks-skincare/

    Now whilst the URL now works, it first has to hit the first URL then redirects to the second, and only then goes to the target.

    Does that make sense?

    Many Thanks

    Plugin Author John Godley

    (@johnny5)

    Why does it redirect from the first to the second?

    It would only do that if you’ve set the target of the first to the source of the second. If that’s not what you want then you should change the target to go where you do want it.

    Thread Starter Rik0399

    (@rik0399)

    Hi John,

    That’s what is weird, the url’s are correct, and yet, when hit, create 404?

    This is why I create the redirect as explained.

    I don’t get it?

    Plugin Author John Godley

    (@johnny5)

    I don’t really get what you are trying to explain.

    You have a URL /dr-david-jacks-skincare/. It is returning a 404. You create two redirects for it. Now it is redirecting.

    If that isn’t the case can you explain it a bit further? Real URLs and real redirects always helps.

    Thread Starter Rik0399

    (@rik0399)

    Okay …

    This is correct :

    /dr-david-jacks-skincare/

    but, shows as a 404?

    But, when I do this :

    /dr-david-jacks-skincare/.*

    /dr-david-jacks-skincare/

    it works – why is that?

    And in addition, having to duplicate what is correct URL, causes a double action?

    Make sense?

    Plugin Author John Godley

    (@johnny5)

    Not really.

    What are you trying to achieve? Which part of Redirection isn’t working?

    Thread Starter Rik0399

    (@rik0399)

    I’m trying to achieve the correct action where a URL (which is correct) does not generate a 404

    Instead, it’s forcing me to create a redirect to the SAME URL which then strangely, works?

    Plugin Author John Godley

    (@johnny5)

    What is forcing you? Why is the correct URL generating a 404? Is this a question about Redirection or your website in general?

    When you write:

    /dr-david-jacks-skincare/.*
    /dr-david-jacks-skincare/

    Is that two redirects or is it /dr-david-jacks-skincare/.* => /dr-david-jacks-skincare/ ?

    Redirecting to the same URL will create loop so you can’t be doing that and the URLs must be different.

    What is the full URL of this page that is returning a 404?

    Thread Starter Rik0399

    (@rik0399)

    Hi,

    Appreciate your time on this …

    “What is forcing you?”

    The 404’s that are being generated from hits

    “Why is the correct URL generating a 404?”

    That’s my point – I don’t know?

    Is this a question about Redirection or your website in general?”

    About redirection

    “When you write:

    /dr-david-jacks-skincare/.*
    /dr-david-jacks-skincare/

    Is that two redirects or is it /dr-david-jacks-skincare/.* => /dr-david-jacks-skincare/ ?”

    /dr-david-jacks-skincare/.* => /dr-david-jacks-skincare/

    “Redirecting to the same URL will create loop so you can’t be doing that and the URLs must be different.”

    This I know

    “What is the full URL of this page that is returning a 404?”

    I don’t want to show here – see your website contact messages πŸ™‚

    • This reply was modified 4 years, 1 month ago by Rik0399.
    Plugin Author John Godley

    (@johnny5)

    I can only advise about Redirection itself, and the behaviour does not appear to be caused by it. Much of what is going on seems to be caused by other things on your site.

    The URL you supplied and the redirects being used show that your site is using a combination of http/https, and www and no www. You are also using Cloudflare and it is possible it is causing problems.

Viewing 13 replies - 1 through 13 (of 13 total)

The topic ‘Query’ is closed to new replies.