Title: exclude css or js by path
Last modified: August 24, 2016

---

# exclude css or js by path

 *  Resolved [mjg2](https://wordpress.org/support/users/mjg2/)
 * (@mjg2)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/)
 * First off, great job on this plugin, so far things appear to be working very 
   well. I had a question for you on a particular use-case involving some plugins
   we use…
 * We are using a couple plugins that include their css and/or js by naming the 
   file using a timestamp to accomplish versioning. The exclude css and exclude 
   js textboxes show examples of entering a specific filename only…
 * Here’s an example of one script that I’d like to exclude but doesn’t have a “
   static” name:
 * <script type=’text/javascript’ src=’//storage.googleapis.com/nelioabtesting/6209123576184832.
   js?ver=4.1.1′></script>
 * Is it possible to exclude the above using a portion of the path (i.e. ‘**nelioabtesting**‘)?
 * Thank you!
 * [https://wordpress.org/plugins/autoptimize/](https://wordpress.org/plugins/autoptimize/)

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

 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/#post-6011148)
 * yes, that is absolutely possible 🙂
 * frank
 *  Thread Starter [mjg2](https://wordpress.org/support/users/mjg2/)
 * (@mjg2)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/#post-6011205)
 * Hi Frank,
    That’s great to hear. Can you point me to any docs or examples on 
   how to accomplish excludes of this style?
 *  Plugin Author [Frank Goossens](https://wordpress.org/support/users/futtta/)
 * (@futtta)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/#post-6011206)
 * There are examples [in the FAQ](https://wordpress.org/plugins/autoptimize/faq/),
   under “How does “exclude from optimizing” work?”. But more generally speaking,
   you can exclude based on any string really;
 * e.g. for
    `//storage.googleapis.com/nelioabtesting/6209123576184832.js?ver=4.1.1′
 * you could use storage.googleapis.com or googleapis.com or nelioabteting or 6209123576184832.
   js or storage.googleapis.com/nelioabtesting or nelioabtesting/6209123576184832.
   js or googleapis.com/nelioabtesting/6209123576184832.js or storage.googleapis.
   com/nelioabtesting/6209123576184832.js … it all depends on how specific you want
   to be.
 * In your case I’d indeed just use ‘nelioabtesting’ or ‘googleapis.com/nelioabtesting’.
 * hope this clarifies,
    frank
 *  Thread Starter [mjg2](https://wordpress.org/support/users/mjg2/)
 * (@mjg2)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/#post-6011207)
 * Absolutely! Thank you very much 🙂

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

The topic ‘exclude css or js by path’ is closed to new replies.

 * ![](https://ps.w.org/autoptimize/assets/icon-256X256.png?rev=2211608)
 * [Autoptimize](https://wordpress.org/plugins/autoptimize/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/autoptimize/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/autoptimize/)
 * [Active Topics](https://wordpress.org/support/plugin/autoptimize/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/autoptimize/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/autoptimize/reviews/)

## Tags

 * [css](https://wordpress.org/support/topic-tag/css/)
 * [exclude](https://wordpress.org/support/topic-tag/exclude/)
 * [js](https://wordpress.org/support/topic-tag/js/)

 * 4 replies
 * 2 participants
 * Last reply from: [mjg2](https://wordpress.org/support/users/mjg2/)
 * Last activity: [11 years, 1 month ago](https://wordpress.org/support/topic/exclude-css-or-js-by-path/#post-6011207)
 * Status: resolved