• Resolved jtm12

    (@jtm12)


    I am getting the 404 notifications from your plugin, but when I click the link in the email to see which page is throwing the 404, there is no link.

    I’ve inspected the element in the email and taken a screen grab of the code. There is no href in the anchor tag, but the anchor tag is there.

    Is there a setting in the plugin that I need to turn on to generate that link correctly?

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Michael Ott

    (@mikeyott)

    Hi,

    Honestly I’m not sure why this would happen. I’ve just tested is and everything seems to work as expected. The link is created by the wp_get_referer() WordPress function.

    That said, the function will return false if the referring URL was the same as the current request URL, and maybe this is what has happened in this case (pure speculation).

    I’m not sure how you would make that happen though, unless you had a link on the page in question which links to itself, and in the split second after you clicked that link an asset suddenly went missing, causing the 404 email notification to be sent without a link. At least, I think that would cause it to happen.

    That’s highly unlikely I know, but it’s the only thing I can think of.

    Are any other 404 notifications working as expected?

    • This reply was modified 4 years, 2 months ago by Michael Ott.
    Thread Starter jtm12

    (@jtm12)

    It looks like I installed the plugin sometime before July 12, and the link in the first notification that I received on July 12 worked. Nothing worked after that. That’s about the time I started trying to fix links not working.

    I’ll just run through what I did, and you might be able to see how I tripped up the plugin.

    I originally built the site years ago as HTML with no SSL certificate. There was a second domain name pointed at the site through my host. Still is. I paid no attention to the site.

    I rebuilt the site this year as a WordPress site and changed it to https://

    I did a lot of Googling to see what pages were ranking and was surprised to see the old parked domain URLs were showing up everywhere, but not the old real domain URLs. Still not sure why. And all the old parked URLs without the https in search pages were throwing 404 errors.

    I installed your plugin and the SEO Redirection plugin and over many days redirected old URLs with the real domain to changed URLs on the new site. And then I redirected all the old URLs from the parked domain to the new site, though that felt like overkill, but it made the links work in search pages.

    I’ll give examples.

    Real domain: https://mysite.com
    Parked domain: https://mysitetoo.com

    Every URL with https://mysite.com/something was redirected to https://mysite.com/replacementpage.

    And every URL with https://mysitetoo.com/something was redirected to https://mysite.com/replacementpage.

    Upon investigation just now, I’m seeing that I redirected https://mysitetoo.com to https://mysite.com.

    My question to you is: If I redirected the parked site to the new site through the SEO Redirection plugin and the host also is forwarding the parked domain to the new domain, have I accomplished what you just described I might have done?

    I should remove the redirected entry for https://mysitetoo.com. I didn’t give it a thought when I did it, but it does seem like a poor choice due to the redundancy.

    I really appreciate you investigating this. Hopefully, my error will save others from creating the same issue.

    Plugin Author Michael Ott

    (@mikeyott)

    Sorry for late reply – I never got notification for some reason :-/

    What you described might have tripped it up. I can’t test that scenario so easily so I can’t confirm for sure. Ultimately if any URL does not exist, be it a page URL, an asset like a stylesheet, js file or image etc, the plugins will send a 404 notification.

    The redirection you did shouldn’t cause the issue, unless the original URL you are redirecting from doesn’t exist. I think as far as the WordPress wp_get_referer() function is concerned it would cause my plugin to trigger a 404 notification because the referring URL was hit first.

    That said, it also depends on how the redirection happens. If it’s via .htaccess then I don’t think it would trigger a 404 notification, because technically a .htaccess redirect could not get WordPress involved until after the redirection occurs.

    Props for all that information you provided. It might be helpful to someone else.

    Thread Starter jtm12

    (@jtm12)

    No need to apologize.

    I have continued to test the plugin and haven’t been sure what update to provide here.

    I removed the redirects that I thought were redundant. I also uninstalled the plugin and then reinstalled it after those redirects were removed. I’m still not getting working links in the notification.

    I feel like I have done something with the redirects that is tripping up your plugin, but I may not be able to figure out the problem. I don’t want to remove them all, though that would be a good way to see if that solves the problem. There are hundreds of redirects now.

    We know the plugin worked when I installed it.

    I think we should let it go.

    I really appreciate your help in describing how the plugin works so I could try to walk through the issue.

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘No link to page in notification email’ is closed to new replies.