{"id":18956901,"date":"2026-07-06T09:11:38","date_gmt":"2026-07-06T09:11:38","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/damages-other-plugins-inline-javascript\/"},"modified":"2026-07-06T09:11:38","modified_gmt":"2026-07-06T09:11:38","slug":"damages-other-plugins-inline-javascript","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/damages-other-plugins-inline-javascript\/","title":{"rendered":"Damages other plugins inline javascript"},"content":{"rendered":"<p>The plugin https:\/\/wordpress.org\/plugins\/wp-photo-album-plus\/ creates inline javascript at the frontend by a call to wp_add_inline_script().<\/p>\n<p>In the page source the result looks like:<\/p>\n<pre><code>&lt;script id=&quot;wppa-js-after&quot;&gt;\njQuery(&quot;body&quot;).append(&#039; &lt;div id=&quot;wppa-overlay-bg&quot; style=&quot;...<\/code><\/pre>\n<p>However on some sites that have the cookie-notice plugin active it is modified into:<\/p>\n<p><code>&lt;script id=&quot;wppa-js-after&quot; class=&quot;hu-blocked&quot; type=&quot;javascript\/blocked&quot; data-script=&quot;&amp;quot;\\njQuery(\\&amp;quot;body\\&amp;quot;).append(&#039; &lt;div id=\\&amp;quot;wppa-overlay-bg\\&amp;quot;...<\/code><\/p>\n<p>Resulting in not working the embedded lightbox implementation anymore.<\/p>\n<p>I, the developer of wp-photo-album-plus, have two questions:<\/p>\n<p>1. Why do you damage other plugins javascript?<br \/>\n2. Is there a setting to prevent this unwanted bahaviour?<\/p>\n<p>Here is a link to my plugins users original support topic:<br \/>\nhttps:\/\/wordpress.org\/support\/topic\/lightroom-not-working\/<\/p>\n","protected":false},"template":"","class_list":["post-18956901","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/18956901","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/18956901\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=18956901"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}