Title: Script code for all posts
Last modified: June 24, 2017

---

# Script code for all posts

 *  Resolved [roberzim](https://wordpress.org/support/users/roberzim/)
 * (@roberzim)
 * [8 years, 11 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/)
 * Hello,
 * I installed and used this great plugin and it works fine.
    I can include scripts
   for each page and post or I can include scripts for all pages and posts without
   distinction. How can I include scripts only for all posts?
 * Thank you,
    rob.

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

 *  Plugin Author [WraithKenny](https://wordpress.org/support/users/wraithkenny/)
 * (@wraithkenny)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/#post-9312352)
 * Typically, I use `if ( ! jQuery('body').hasClass('archive') ) { return; }` before
   the code I want to run only on blog style pages. You might have to inspect different
   types of post pages to get the correct combination of body classes.
 *  [deftones fan](https://wordpress.org/support/users/deft1z/)
 * (@deft1z)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/#post-9323632)
 * Hello!
 * Thnx very much for the plugin. I need some help. Everything works great but plugin
   doesn’t add to the product category admin pages in woocommerce.
 * Gere is the body class of that page
    “<body class=”archive tax-product_cat term-
   ajax-keypad term-210 _masterslider _msp_version_2.26.0 woocommerce woocommerce-
   page loaded headhesive”><header class=”banner navbar navbar-default navbar-static-
   top dark-header headhesive–clone” role=”banner”>”
 * How can I do that the Plugin: Scripts n Styles will be added to all admin pages
 * Thank You in advance
 *  [aumattc](https://wordpress.org/support/users/aumattc/)
 * (@aumattc)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/#post-9345648)
 * Hello,
 * The plugin works exactly what I want until recently. I receive the following 
   error on Post and Page editor whenever I do the ‘Add media’ or ‘Feature images’
   action.
 * Failed to load content css: [http://fittygang.com/wp-admin/admin-ajax.php?_wpnonce=5fde5abd69&post_id=3155&action=sns_tinymce_styles](http://fittygang.com/wp-admin/admin-ajax.php?_wpnonce=5fde5abd69&post_id=3155&action=sns_tinymce_styles)
 * I thought it should have something to do with one of your code.
 * Can you help me to sort this out please?
 * Cheers,
 * Matt
 *  Plugin Author [WraithKenny](https://wordpress.org/support/users/wraithkenny/)
 * (@wraithkenny)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/#post-9378134)
 * [@deft1z](https://wordpress.org/support/users/deft1z/) The plugin adds itself
   to every public single post type. It doesn’t add itself to archives or taxonomies.
   For those, you should use the global boxes and scope it to the appropriate body
   class.
 * [@aumattc](https://wordpress.org/support/users/aumattc/) Thanks for the bug report,
   I’ll see what I can find out.

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

The topic ‘Script code for all posts’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/scripts-n-styles_46515d.svg)
 * [Scripts n Styles](https://wordpress.org/plugins/scripts-n-styles/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/scripts-n-styles/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/scripts-n-styles/)
 * [Active Topics](https://wordpress.org/support/plugin/scripts-n-styles/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/scripts-n-styles/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/scripts-n-styles/reviews/)

 * 4 replies
 * 4 participants
 * Last reply from: [WraithKenny](https://wordpress.org/support/users/wraithkenny/)
 * Last activity: [8 years, 9 months ago](https://wordpress.org/support/topic/script-code-for-all-posts/#post-9378134)
 * Status: resolved