Title: [Plugin: Shadowbox JS] Not loading custom css file
Last modified: August 20, 2016

---

# [Plugin: Shadowbox JS] Not loading custom css file

 *  [hafman](https://wordpress.org/support/users/hafman/)
 * (@hafman)
 * [14 years, 8 months ago](https://wordpress.org/support/topic/plugin-shadowbox-js-not-loading-custom-css-file/)
 * Hello,
    Using Shadowbox JS version 3.0.3.8 I’m trying to load a custom css file
   from my theme as documented on the plugin page. I’ve followed the procedure to
   the letter (except – read below!) yet shadowbox.css is stubbornly loading from
   the plugin directory.
 * Also the instructions mention a ‘functions.js’ file, does that exist in any WordPress
   theme? I used functions.php anyway.
 * [http://wordpress.org/extend/plugins/shadowbox-js/](http://wordpress.org/extend/plugins/shadowbox-js/)

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

 *  [duepi.biz](https://wordpress.org/support/users/duepibiz/)
 * (@duepibiz)
 * [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-shadowbox-js-not-loading-custom-css-file/#post-2349351)
 * Same here…
    Have you found any other solution than editing the plugin files ?
   Tanks in advance P.
 *  Plugin Author [Matt Martz](https://wordpress.org/support/users/sivel/)
 * (@sivel)
 * [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-shadowbox-js-not-loading-custom-css-file/#post-2349353)
 * Try placing the code in a new plugin, or a mu-plugin.
 * if you create a directory at /wp-content/mu-plugins and create a php file of 
   any name in there and paste in the following code:
 *     ```
       <?php
       function custom_shadowbox_css($url) {
           return get_bloginfo('stylesheet_directory') . '/css/shadowbox.css';
       }
       add_filter('shadowbox-css', 'custom_shadowbox_css');
       ?>
       ```
   
 * You will be good to go.
 *  [duepi.biz](https://wordpress.org/support/users/duepibiz/)
 * (@duepibiz)
 * [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-shadowbox-js-not-loading-custom-css-file/#post-2349354)
 * Hy Matt and thanks for your quick response!
 * What i’m trying to do is to add
 *     ```
       function custom_shadowbox_css($url) {
           return get_bloginfo('stylesheet_directory') . '/css/shadowbox.css';
       }
       add_filter('shadowbox-css', 'custom_shadowbox_css');
       ```
   
 * in functions.php of my child theme only if the plugin is present and active.
 * Well, i think there is some synchronization issue between inc/frontend.php apply_filters
   call and add_filter in functions.php; do you think it’s possible ?
    Can you give
   me any tips ?
 * Once again, thank’s in advance
    P.

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

The topic ‘[Plugin: Shadowbox JS] Not loading custom css file’ is closed to new 
replies.

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

 * 3 replies
 * 3 participants
 * Last reply from: [duepi.biz](https://wordpress.org/support/users/duepibiz/)
 * Last activity: [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-shadowbox-js-not-loading-custom-css-file/#post-2349354)
 * Status: not resolved