Title: Javavscript conflict
Last modified: May 10, 2019

---

# Javavscript conflict

 *  Resolved [shawfactor](https://wordpress.org/support/users/shawfactor/)
 * (@shawfactor)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/javavscript-conflict/)
 * the gutenberg.min.js is causing a javascript conflict with ajax elsewhere on 
   my site.
 * There is a simple fix, only enqueue it where it is needed, ie in the editor. 
   I have done so by changing plugin.php around 291 thus:
 * $screen = get_current_screen();
 *  if ( $screen->parent_base == ‘edit’ ) {
 *  // Gutenberg.
    wp_enqueue_script( ‘plt-gutenberg’, $this->get_url() . ‘js/gutenberg.
   min.js’, array( ‘wp-edit-post’, ‘wp-element’, ‘wp-plugins’ ), self::CSS_JS_VERSION,
   true );
 *  }
 * This is probaby god practice anyway, although I am sure there is a better way
   to do it than I have. Can this change be added to the core plugin?
 * Pete
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fjavavscript-conflict%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [shawfactor](https://wordpress.org/support/users/shawfactor/)
 * (@shawfactor)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/javavscript-conflict/#post-11519627)
 * Now resolved in latest version
 *  [Blulab Srl](https://wordpress.org/support/users/blulabsrl/)
 * (@blulabsrl)
 * [7 years ago](https://wordpress.org/support/topic/javavscript-conflict/#post-11564889)
 * Hi, we also have an Javascript Error, but we have installed last WP version and
   last Page Links To version.
 * _Uncaught ReferenceError: pltVars is not defined
    at HTMLDocument.<anonymous>(
   quick-add.jsx:15) at i (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,
   utils,jquery-ui-core,jquery-ui-widget,jquery-ui-mouse,jquery-ui-resizable,jquery-
   ui-position,jquery-u&load[]=i-sortable,jquery-ui-tooltip&ver=5.2.1:2) at Object.
   fireWith [as resolveWith] (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,
   utils,jquery-ui-core,jquery-ui-widget,jquery-ui-mouse,jquery-ui-resizable,jquery-
   ui-position,jquery-u&load[]=i-sortable,jquery-ui-tooltip&ver=5.2.1:2) at Function.
   ready (load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-
   core,jquery-ui-widget,jquery-ui-mouse,jquery-ui-resizable,jquery-ui-position,
   jquery-u&load[]=i-sortable,jquery-ui-tooltip&ver=5.2.1:2) at HTMLDocument.J (
   load-scripts.php?c=0&load[]=jquery-core,jquery-migrate,utils,jquery-ui-core,jquery-
   ui-widget,jquery-ui-mouse,jquery-ui-resizable,jquery-ui-position,jquery-u&load[]
   =i-sortable,jquery-ui-tooltip&ver=5.2.1:2)
 * By now we removed latest release and we will install the stable release 2.9.2:
   
   Could you verify?
 * Thanks a lot
    Ileana, Blulab Srl

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Javavscript conflict’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/page-links-to_fafafa.svg)
 * [Page Links To](https://wordpress.org/plugins/page-links-to/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/page-links-to/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/page-links-to/)
 * [Active Topics](https://wordpress.org/support/plugin/page-links-to/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/page-links-to/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/page-links-to/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Blulab Srl](https://wordpress.org/support/users/blulabsrl/)
 * Last activity: [7 years ago](https://wordpress.org/support/topic/javavscript-conflict/#post-11564889)
 * Status: resolved