{"id":11926781,"date":"2019-09-12T18:37:55","date_gmt":"2019-09-12T18:37:55","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/formstack-javascript-error\/"},"modified":"2019-09-12T18:37:55","modified_gmt":"2019-09-12T18:37:55","slug":"formstack-javascript-error","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/formstack-javascript-error\/","title":{"rendered":"Formstack JavaScript Error"},"content":{"rendered":"<p>Hi,<\/p>\n<p>There is an issue with the formstack plugin when using Advanced Custom Fields within a WordPress site. Advanced Custom Fields is a very widely used page builder tool so we&#8217;d assume this issue comes up a lot.<\/p>\n<p>When using the Advanced Custom Fields WYSIWYG editor field, the formstack plugin throws an error message. This only occurs on special pages (options, author pages, menu pages) &#8211; sections in WordPress that wouldn&#8217;t typically have WYSIWYG editor fields present.<\/p>\n<p>We&#8217;ve developed a fix to at least not throw the large red error banners, but ideally the plugin would work in those locations as well.<\/p>\n<p>The user displayed error is:<br \/>\nFailed to initialize plugin: Formstack.<\/p>\n<p>The JS error that is shown in the console is:<br \/>\nFailed to initialize plugin: formstack ReferenceError: formstack_tinymce is not defined<\/p>\n<p>We have implemented a fix on our version of the plugin which is to this file:<br \/>\n\/wp-content\/plugins\/formstack\/tinymce\/plugin.js<\/p>\n<p>The fix is to add this code after line 2 in that JS file:<br \/>\nif (typeof formstack_tinymce == &#8216;undefined&#8217;) {<br \/>\nreturn;<br \/>\n}<\/p>\n<p>Often when the formstack plugin is updated it overwrites our changes so it would be great if you would consider updating the plugin.<\/p>\n<p>Thanks for your help!!<\/p>\n<p>Joe<\/p>\n","protected":false},"template":"","class_list":["post-11926781","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/11926781","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\/11926781\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=11926781"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}