• Resolved avee8rmike

    (@avee8rmike)


    I implemented this AMP plugin several months ago – its never seemed to be truly happy in Google search console so now I thought I would get an opinion here. I get an error on the home page of the site that I don’t understand and thus don’t know how to fix. If I’m reading the error correctly it would appear that its having a problem with my small gravity form on the page.

    I get this error :

    Validation issues
    The tag ‘amp-iframe’ is missing a mandatory attribute – pick one of [‘src’, ‘srcdoc’].

    and it highlights this code :

    <amp-iframe id=”gform_ajax_frame_18″ sandbox=”allow-scripts allow-same-origin” height=”400″ layout=”fixed-height” class=”amp-wp-db0bb1b”><span placeholder=”” class=”amp-wp-iframe-placeholder”></span></amp-iframe>

    any ideas ?

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

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Pascal Birchler

    (@swissspidy)

    Gravity Forms is not AMP compatible out of the box, especially not when using Ajax submitted forms.

    In the past I have put together some code that can be used to make Gravity Forms mostly AMP compatible. You can find it here: https://gist.github.com/swissspidy/86e3a50ec5c0f7d46ec4de43824e23a0

    A little less code is needed if you do not use Ajax form submissions: https://gist.github.com/westonruter/b2554073461707a88057bb86b6b603d6

    In the future I might make my code into a fully fledged plugin, but at the moment it’s all there is, which means it requires some PHP development knowledge.

    You might also want to contact Gravity Forms to ask for built-in AMP compatibility, as it would be on them to make it actually work out of the box.

    Hope that helps!

    Thread Starter avee8rmike

    (@avee8rmike)

    Hi Pascal – many thanks for responding. So now I have to admit – I havn’t got a clue what to do with that code ! Do I create a new file, edit an existing file ? Or wholly Replace an existing file ? and if so where does that file live ? Sorry – never edited PHP before ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Invalid usage of AMP tags (Critical issue)’ is closed to new replies.