• Resolved Muhammad Junaid

    (@mj00712)


    Hi. I hope you are doing well. I get this error after performing an AMP compatibility check that shows neve theme has some incompatibility. Please check

    [
    {
    "url": "https://filectory.com/bank-of-khyber-bok-jobs-2024-apply-online/",
    "type": "is_singular[post]",
    "label": "Post",
    "amp_url": "https://filectory.com/bank-of-khyber-bok-jobs-2024-apply-online/amp/",
    "validation_errors": [
    {
    "node_name": "script",
    "parent_name": "form",
    "code": "DISALLOWED_TAG",
    "type": "js_error",
    "node_attributes": {
    "type": "text/javascript"
    },
    "text": "\n/* /\n(function(){if(window===window.parent){document.getElementById(SINGLE_QUOTED_STRING).name=SINGLE_QUOTED_STRING;}})();\n/ ]]> */\n",
    "node_type": 1,
    "sources": [
    {
    "type": "theme",
    "name": "neve",
    "file": "inc/views/partials/comments.php",
    "line": 39,
    "function": "Neve\Views\Partials\Comments::render_comment_form",
    "hook": "neve_do_comment_area",
    "priority": 10
    }
    ]
    }
    ],
    "stale": false,
    "error": false,
    "validated_url_post": {
    "id": 29274,
    "edit_link": "https://filectory.com/wp-admin/post.php?post=29274&action=edit"
    }
    }
    ]
Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi Muhammad,

    Thank you for reporting this. I’ve tried replicating this but unfortunately wasn’t able to do it https://vertis.d.pr/i/uxApsr.

    I’ve tried on a fresh instance with just Neve, no other plugins to make sure the problem is not coming from somewhere else and there were no errors. I suspect in your case that the issue is either related to a plugin you are using or some customizations you might have done to the theme.

    If it’s of any help, I suggest you also have a look here where we have all the details related to Neve’s compatibility with AMP https://docs.themeisle.com/article/1078-amp-support-in-neve

    Regards,

    Rodica

    Thread Starter Muhammad Junaid

    (@mj00712)

    Information
    AMP does not allow the use of JS <script> tags unless they are for loading AMP components, which are added automatically by the AMP plugin. For any page to be served as AMP, all invalid script tags must be removed from the page. Instead of custom or third-party JS, please consider using AMP components and functionality such as amp-bind and actions and events (as opposed to JS event handler attributes like onclick). Some custom JS can be added if encapsulated in the amp-script. Learn more about how AMP works.
    
    If all invalid markup is “removed” the page will be served as AMP. However, the impact that the removal has on the page must be assessed to determine if the result is acceptable. If any invalid markup is “kept” then the page will not be served as AMP.
    
    Error code
    DISALLOWED_TAG
    Invalid markup
    <script>
    Element name
    script
    Parent element
    form
    Text content
    Sources
    #1	Type:	 Theme
    Name:	Neve (neve)
    Function:	Neve\Views\Partials\Comments::render_comment_form()
    Action:	neve_do_comment_area (priority 10)
    Location:	inc/views/partials/comments.php:39
    #2	Type:	 Core
    Name:	wp-includes
    Function:	wp_comment_form_unfiltered_html_nonce()
    Action:	comment_form (priority 10)
    Location:	comment-template.php:1363

    Hi,

    You didn’t provide more information on whether you have some customizations done to the theme, or if you’ve tried disabling any other plugin you have to see if there might be an incompatibility there.

    You can also share the settings you have in the AMP plugin. If they follow what we have here https://docs.themeisle.com/article/1078-amp-support-in-neve

    Regards

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘AMP Incompatibility’ is closed to new replies.