Title: 2 problems with javascript ignition in header
Last modified: August 21, 2016

---

# 2 problems with javascript ignition in header

 *  Resolved [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/)
 * Hi,
    I have 2 problems with javascript: – first: how can I load wordpress specific
   javascripts in header? – second: when I click on a category to access all posts
   with the same category the plug-in do not load prestashop javascript but instead
   the wordpress specific ones; css instead are correctly loaded.
 * If you want to see the pages:
    – [store.marioscrafts.com/blog/category/eventi/](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/?output_format=md)
 * Thanks,
    Andrea
 * [http://wordpress.org/extend/plugins/prestashop-integration/](http://wordpress.org/extend/plugins/prestashop-integration/)

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

 *  Plugin Author [aytechnet](https://wordpress.org/support/users/aytechnet/)
 * (@aytechnet)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722113)
 * Hi,
 * This plugin is light on CSS/JS integration : it only adds the CSS and JS if the
   corresponding configuration enable it.
 * It does not try to be clever by reconfiguring PrestaShop JS or WordPress JS. (
   only JS can be tedious as some libraries may conflict together).
    So if you add
   a plugin in WordPress that requires JQuery, the plugin will make WordPress fetch
   it even if it is already loaded by PrestaShop. You need to fix by hand theses
   problems : generally it is better to use only PrestaShop JS and deactivate the
   WordPress one (because PrestaShop will not work anymore if you use an already
   well up-to-date Jquery, which WordPress generally is bundled with). So you may
   need to use : wp_deregister_script to disable the WordPress one.
 * For loading PrestaShop one : the easiest way will be to edit FrontController 
   class to add the needed Javascript, it is ugly but PrestaShop Integration plugin
   create a dummy Controller class which inherit the FrontController of PrestaShop.
   So adding the necessary stuff in FrontController will make it available for WordPress
   as well. It would be nicer to add a specific hooks in functions.php of your WordPress
   theme (so it is a feature request).
 * Kind Regards,
    François.
 *  Thread Starter [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722244)
 * Thank you François,
 * I have deregistered jQuery but I have still a difference between the root and
   the single post js+css ([http://store.marioscrafts.com/blog/](http://store.marioscrafts.com/blog/)
   and [http://store.marioscrafts.com/blog/design-mostra-marios-ancora-ospite-di/](http://store.marioscrafts.com/blog/design-mostra-marios-ancora-ospite-di/))
   and the category listing js+css ([http://store.marioscrafts.com/blog/category/blog/](http://store.marioscrafts.com/blog/category/blog/)–
   which seems to be the right one).
 * How can I have the same js+css in both?
 * Regards,
    Andrea
 *  Thread Starter [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722245)
 * ok, I have found a little more info to solve the problem:
 * – in the root and the single post the js and css loaded are the prestashop ones
   and the wordpress one are not loaded;
    – in the category listing js and css are
   the wordpress ones and the prestashop ones are not loaded.
 * Is it possible to load in both cases the prestashop and the wordpress js+css 
   at the same time?
 * Andrea
 *  Thread Starter [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722246)
 * ok, I have found the error: in the configuration page in the field “PrestaShop
   path:” I have written “../” because I have wordpress in a subdirectory called
   blog.
 * I tried to find the way to write an absolute path but with no success.
 * What’s the right way to insert the absolute path?
 * Best Regards,
    Andrea
 *  Thread Starter [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722248)
 * ok, resolved…
    … it was a code snippet left on another integration trial…
 * Now everything works well!
 * Andrea
 *  Thread Starter [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * (@andrearuffini)
 * [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722249)
 * Resolved

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

The topic ‘2 problems with javascript ignition in header’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/prestashop-integration.svg)
 * [PrestaShop Integration](https://wordpress.org/plugins/prestashop-integration/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/prestashop-integration/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/prestashop-integration/)
 * [Active Topics](https://wordpress.org/support/plugin/prestashop-integration/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/prestashop-integration/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/prestashop-integration/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [andrearuffini](https://wordpress.org/support/users/andrearuffini/)
 * Last activity: [13 years ago](https://wordpress.org/support/topic/2-problems-with-javascript-ignition-in-header/#post-3722249)
 * Status: resolved