Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jigsaw::add_css allow for use with child themes #12

Open
lmartins opened this issue Jan 13, 2015 · 2 comments
Open

Jigsaw::add_css allow for use with child themes #12

lmartins opened this issue Jan 13, 2015 · 2 comments

Comments

@lmartins
Copy link

Because it's prepending the theme directory to the request URL, it doesn't allow child-theme to use this helper.

@sidonaldson
Copy link

I hit this issue today as well. 👍

@sidonaldson
Copy link

For anyone wanting a quick fix for this in the mean time:

add_action( 'admin_enqueue_scripts', function() {
      $file = get_template_directory_uri() . "/child/overrides.css";
      wp_enqueue_style('app-theme-customisations', str_replace('base-theme','child-theme',$file));
    } );

where 'base-theme' and 'child-theme' are the difference in url path to the file (as get_template_directory_uri() only returns the base theme)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants