{"id":18676,"date":"2021-06-15T14:24:34","date_gmt":"2021-06-15T11:24:34","guid":{"rendered":"https:\/\/plumrocket.com\/docs\/?p=18676"},"modified":"2021-07-22T08:22:03","modified_gmt":"2021-07-22T12:22:03","slug":"incorrect-script-tags-placement-2","status":"publish","type":"post","link":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location","title":{"rendered":"Incorrect \u201cscript\u201d tags placement"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">In some cases AMP is not valid because the script tags are in the &#8220;body&#8221; part of the HTML page.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This can be caused by the third-party extension that moves &#8220;script&#8221; tags from &#8220;head&#8221; to the end of &#8220;body&#8221; part of the HTML page.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Solution<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">You need to set the third-party extension in a specific way, so it will not be running on <a href=\"\/magento-amp\">Magento 2 AMP pages<\/a>. These configurations can be performed in the extension&#8217;s settings or you can make minor code modifications.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>For this purpose contact your third-party extension developers or our&nbsp;<a href=\"\/contacts\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">support service<\/a>.<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In some cases AMP is not valid because the script tags are in the &#8220;body&#8221; part of the HTML page. This can be caused by the third-party extension that moves &#8220;script&#8221; tags from &#8220;head&#8221; to the end of &#8220;body&#8221; part of the HTML page. Solution You need to set the third-party extension in a specific &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Incorrect \u201cscript\u201d tags placement&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[106],"tags":[],"class_list":["post-18676","post","type-post","status-publish","format-standard","hentry","category-troubleshooting-v3","entry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v17.2 (Yoast SEO v28.1) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Incorrect \u201cscript\u201d tags placement - Plumrocket Documentation<\/title>\n<meta name=\"description\" content=\"In some cases AMP is not valid because the script tags are in the &quot;body&quot; part of the HTML page. This can be caused by the third-party extension that moves\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Incorrect \u201cscript\u201d tags placement\" \/>\n<meta property=\"og:description\" content=\"In some cases AMP is not valid because the script tags are in the &quot;body&quot; part of the HTML page. This can be caused by the third-party extension that moves\" \/>\n<meta property=\"og:url\" content=\"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location\" \/>\n<meta property=\"og:site_name\" content=\"Plumrocket Documentation\" \/>\n<meta property=\"article:published_time\" content=\"2021-06-15T11:24:34+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-07-22T12:22:03+00:00\" \/>\n<meta name=\"author\" content=\"Plumrocket\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Plumrocket\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Incorrect \u201cscript\u201d tags placement - Plumrocket Documentation","description":"In some cases AMP is not valid because the script tags are in the \"body\" part of the HTML page. This can be caused by the third-party extension that moves","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location","og_locale":"en_US","og_type":"article","og_title":"Incorrect \u201cscript\u201d tags placement","og_description":"In some cases AMP is not valid because the script tags are in the \"body\" part of the HTML page. This can be caused by the third-party extension that moves","og_url":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location","og_site_name":"Plumrocket Documentation","article_published_time":"2021-06-15T11:24:34+00:00","article_modified_time":"2021-07-22T12:22:03+00:00","author":"Plumrocket","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Plumrocket","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location#article","isPartOf":{"@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location"},"author":{"name":"Plumrocket","@id":"https:\/\/plumrocket.com\/docs\/#\/schema\/person\/38b360639b934d6c984ee4f3ffce7d20"},"headline":"Incorrect \u201cscript\u201d tags placement","datePublished":"2021-06-15T11:24:34+00:00","dateModified":"2021-07-22T12:22:03+00:00","mainEntityOfPage":{"@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location"},"wordCount":100,"articleSection":["Troubleshooting"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location","url":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location","name":"Incorrect \u201cscript\u201d tags placement - Plumrocket Documentation","isPartOf":{"@id":"https:\/\/plumrocket.com\/docs\/#website"},"datePublished":"2021-06-15T11:24:34+00:00","dateModified":"2021-07-22T12:22:03+00:00","author":{"@id":"https:\/\/plumrocket.com\/docs\/#\/schema\/person\/38b360639b934d6c984ee4f3ffce7d20"},"description":"In some cases AMP is not valid because the script tags are in the \"body\" part of the HTML page. This can be caused by the third-party extension that moves","breadcrumb":{"@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting\/script-tag-location#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Magento 2 Extensions","item":"https:\/\/plumrocket.com\/magento-extensions"},{"@type":"ListItem","position":2,"name":"Magento 2 AMP","item":"https:\/\/plumrocket.com\/magento-amp"},{"@type":"ListItem","position":3,"name":"Documentation","item":"https:\/\/plumrocket.com\/docs\/magento-amp"},{"@type":"ListItem","position":4,"name":"v3","item":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3"},{"@type":"ListItem","position":5,"name":"Troubleshooting","item":"https:\/\/plumrocket.com\/docs\/magento-amp\/v3\/troubleshooting"},{"@type":"ListItem","position":6,"name":"Incorrect \u201cscript\u201d tags placement"}]},{"@type":"WebSite","@id":"https:\/\/plumrocket.com\/docs\/#website","url":"https:\/\/plumrocket.com\/docs\/","name":"Plumrocket Documentation","description":"Extensions docs, troubleshootings etc.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/plumrocket.com\/docs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/plumrocket.com\/docs\/#\/schema\/person\/38b360639b934d6c984ee4f3ffce7d20","name":"Plumrocket","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/85ed2f38dbe6a031f443b1949101e9b31bbd6985eae2cac6695629e7ad280aee?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/85ed2f38dbe6a031f443b1949101e9b31bbd6985eae2cac6695629e7ad280aee?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/85ed2f38dbe6a031f443b1949101e9b31bbd6985eae2cac6695629e7ad280aee?s=96&d=mm&r=g","caption":"Plumrocket"},"sameAs":["https:\/\/plumrocket.com\/docs"]}]}},"_links":{"self":[{"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/posts\/18676","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/comments?post=18676"}],"version-history":[{"count":1,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/posts\/18676\/revisions"}],"predecessor-version":[{"id":22289,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/posts\/18676\/revisions\/22289"}],"wp:attachment":[{"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/media?parent=18676"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/categories?post=18676"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/plumrocket.com\/docs\/wp-json\/wp\/v2\/tags?post=18676"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}