• Resolved ellen413

    (@ellen413)


    Hello,
    My site health is ‘good’ with only one recommendation for improvement, unrelated to AMP. The site is here: https://bit.ly/2Q5x21D

    I started fooling around with AMP several weeks ago. I had several errors, but they all could be removed without consequence. However, I decided to switch themes from one that was not listed on the ‘ecosystem’ (https://amp-wp.org/ecosystem/) – to one that was on the list.

    Right after the theme switch, I got a new message:

    URL validation failed to due to the absence of the expected JSON-containing AMP_VALIDATION HTML comment after </body>. This is often due to a PHP fatal error occurring. Please check your server PHP error logs; to do this you may need to enable WP_DEBUG_LOG. If you are stuck, please search the support forum for possible related topics, or otherwise start a new support topic including the error message, the URL to your site, and your active theme/plugins. Please include your Site Health Info.

    My active theme is Zakra. I switched from OceanWP.

    Active plugins:
    AMP
    Accelerated Mobile Pages (Addon mode)
    Site Kit by Google
    Akismet
    Share Buttons by AddThis
    Jetpack by WordPress
    MC4WP: Mailchimp for WordPress
    Rank Math SEO
    Smush
    Ultimate Blocks
    Updraft Plus
    *I disabled W3 Total Cache based on older support forum threads, but I don’t think that’s the problem. Then again, I don’t know what I’m doing. I read the php debug stuff and I started to get a headache. (I have since re-enabled the cache plug in.)

    Thanks for any help/guidance you can give.

    Regards,
    Ellen

    The page I need help with: [log in to see the link]

Viewing 15 replies - 1 through 15 (of 15 total)
  • Plugin Author Weston Ruter

    (@westonruter)

    @ellen413 Hello! Please check Site Health in your WP Admin. First make sure that loopback requests are working.

    Also what is this plugin: “Accelerated Mobile Pages (Addon mode)”?

    The issue you are facing may be due to W3 Total Cache stripping HTML comments from the response. This issue was reported previously here: https://github.com/ampproject/amp-wp/issues/3887 and https://github.com/ampproject/amp-wp/issues/3970

    The fix for that issue has been merged but it is not yet in a stable release.

    Please try the 1.5.0-alpha plugin build linked to here: https://github.com/ampproject/amp-wp/issues/3970#issuecomment-567585925

    Thread Starter ellen413

    (@ellen413)

    Hello, @westonruter!

    Site Health = good. I don’t know what loopback requests are – I see nothing of that nature.

    The plugin is:
    AMP for WP – Accelerated Mobile Pages for WordPress
    Version 1.0.2 | By Ahmed Kaludi, Mohammed Kaludi | View details |

    The W# Total Cache was deactivated, but I still had the problem.

    I read through github, and have trouble understanding things.

    The 1.5.0-alpha plugin build you linked to: what do I do with that file once I download it? I’m afraid I’m not tech savvy and all I can do is try piece by piece and learn as I go. Do I need that plugin? Should I just ignore the message?

    Thanks,
    Ellen

    Plugin Author Weston Ruter

    (@westonruter)

    One of the tests in Site Health is for loopback requests. If that is among the passed tests then that isn’t the problem.

    I’m confused about why you are using the official AMP plugin and the AMP for WP plugin. You should only use one or the other.

    The plugin build I linked to is something you can install into WordPress as a replacement for the AMP plugin. You would first deactivate and uninstall the current version and then install the alpha version via the instructions at https://codex.www.ads-software.com/Plugins_Add_New_Screen#Upload_Plugins

    Thread Starter ellen413

    (@ellen413)

    I don’t see the loopback requests in the Site Health Info. I opened all test areas and read through them all. Also searched “loopback” and there is nothing…?

    I’m using both AMP plugins to get a few more options on the look of the site, and ‘add on’ mode is supposedly compatible with the official AMP plugin.

    Thanks for explaining the alternative plugin replacement. I will follow instructions and see what happens. (I’m 13 hours ahead of NYC time, at the moment…)

    Thanks again for the attention and suggestions.
    Best regards,
    Ellen

    Thread Starter ellen413

    (@ellen413)

    Learning something new every day…

    I have these two messages at the top:
    You appear to have installed the AMP plugin incorrectly. It is currently installed in the amp-1 directory, but it needs to be placed in a directory named amp. Please rename the directory. This is important for WordPress plugin auto-updates.
    The AMP plugin‘s post-processor cache was disabled due to the detection of highly-variable content. More details

    And this message further down:
    The post-processor cache was disabled due to detecting randomly generated content found on on this web page.
    Randomly generated content was detected on this web page. To avoid filling up the cache with unusable content, the AMP plugin’s post-processor cache was automatically disabled. Read more.

    I enabled the post-processor cache.
    I’m in Transitional mode.
    I tested the site with /?amp and there are 18 validation issues, all removable without visible consequence. This is what it was like before I switched themes from OceanWP to Zakra.

    I’m assuming the amp-1 directory is because it’s a not-for-release version? Is that what ‘alpha’ means?

    Thank you,
    Ellen

    Thread Starter ellen413

    (@ellen413)

    Wow, @westonruter! There are many new features to like with this amp build. I love it!

    Plugin Author Weston Ruter

    (@westonruter)

    I’m assuming the amp-1 directory is because it’s a not-for-release version? Is that what ‘alpha’ means?

    It may actually be because you already had an amp directory when attempting to install the new AMP plugin build, so it created a new directory name upon upload. I’m not sure. You may need to fix the directory name using SFTP.

    This is important to do so that you get automatic updates properly.

    • This reply was modified 4 years, 9 months ago by Weston Ruter.
    Plugin Author Weston Ruter

    (@westonruter)

    And this message further down:
    The post-processor cache was disabled due to detecting randomly generated content found on on this web page.
    Randomly generated content was detected on this web page. To avoid filling up the cache with unusable content, the AMP plugin’s post-processor cache was automatically disabled. Read more.

    I enabled the post-processor cache.

    This is a common occurrence. We need to re-work how the post-processor cache works, or else remove it, because it very frequently gets turned off because of variable content. Ultimately you should be using a page caching plugin anyway, something which is a best performance practice for WordPress sites in general.

    Feel free to leave it unchecked.

    • This reply was modified 4 years, 9 months ago by Weston Ruter.
    Plugin Author Weston Ruter

    (@westonruter)

    I don’t see the loopback requests in the Site Health Info. I opened all test areas and read through them all. Also searched “loopback” and there is nothing…?

    That’s strange. It should be there. Did you wait for the tests to complete? Make sure the “Results are still loading…” message is cleared at the top before checking.

    Plugin Author Weston Ruter

    (@westonruter)

    I’m using both AMP plugins to get a few more options on the look of the site, and ‘add on’ mode is supposedly compatible with the official AMP plugin.

    I have not verified this to be the case. What features specifically are you looking for that are not in the official AMP plugin? The goal of the AMP plugin is to be focused on one thing: facilitating a site to serve AMP pages in a way that integrates fully into WordPress’s normal content creation flows.

    The AMP plugin is intended to allow you to use your active theme’s design for serving AMP pages, so there is no longer a difference between AMP and non-AMP. Plus in Standard mode you can serve your entire site as AMP without there being any non-AMP version. This is called “AMP-first” by the AMP Project. This allows for Desktop and Mobile visitors alike to get the same speed benefits of AMP. Originally AMP stood for “Accelerated Mobile Pages” because it was first developed to improve the user experience on the mobile web; now, however, AMP is just about improving the user experience on the web in general, so “AMP” now just stands for “AMP” (it is no longer an acronym).

    In order to add some additional feature to AMP pages on your site, our goal is for site owners to just install plugins from www.ads-software.com as they normally do for such features. Our ecosystem page lists themes and plugins that have been tested for compatibility, and more themes and plugins are being added all the time. Jetpack is mostly AMP-compatible and work is underway to make it fully compatible. So if you need Related Posts on your site, just use the Related Posts module in Jetpack. If you want SEO support, use Yoast. If you want Google Analytics or AdSense, use Site Kit. And so on.

    Thread Starter ellen413

    (@ellen413)

    It may actually be because you already had an amp directory when attempting to install the new AMP plugin build, so it created a new directory name upon upload. I’m not sure. You may need to fix the directory name using SFTP.

    This is important to do so that you get automatic updates properly.

    Got it. Thank you. The original 1.4 version was deactivated, not deleted, upon install. I deleted both versions, and reinstalled the plugin build and no longer have that message.

    Thread Starter ellen413

    (@ellen413)

    That’s strange. It should be there. Did you wait for the tests to complete? Make sure the “Results are still loading…” message is cleared at the top before checking.

    Just checked a third time. Opened all info drop downs – looked and searched “loopback” and there is nothing. Also copied to clipboard, pasted into document, searched. Nothing.

    I deleted the following plugins that are not in the amp ‘ecosystem’:
    Accelerated Mobile Pages (Addon mode)
    Rank Math
    Smush

    Still using:
    MC4WP: Mailchimp for WordPress
    Ultimate Blocks
    Updraft Plus
    W3 Total Cache
    — not in the ecosystem

    I have no idea if a plugin might be why I’m not seeing loopback requests in Site Health. I had to search what they are – but admittedly don’t really get why this is important. On one help forum, someone said a backup theme caused the issue (?).

    While my Site Health is ‘good’ – there is:
    “1 recommended improvement

    Themes add your site’s look and feel. It’s important to keep them up to date, to stay consistent with your brand and keep your site secure.

    Your site has 1 installed theme, and it is up to date.

    Your site does not have any default theme. Default themes are used by WordPress automatically if anything is wrong with your normal theme.”

    Could this possibly be the answer? I have not yet looked at how to name a default theme.

    Thank you for all of your time and help. I’m learning a lot, and hopefully this thread can serve others.

    Best regards,
    Ellen

    Plugin Author Weston Ruter

    (@westonruter)

    Are you still getting that URL validation failed message?

    Thread Starter ellen413

    (@ellen413)

    No. I haven’t seen it since I properly installed the plugin zip file.

    Plugin Author Weston Ruter

    (@westonruter)

    Excellent. Then the fix is verified.

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘URL validation failed message’ is closed to new replies.