Last active
August 25, 2016 22:54
-
-
Save jpen365/3814f67e02ddd6abd8bd5fdd001d1f23 to your computer and use it in GitHub Desktop.
Enqueue a CSS and JS file as part of a plugin.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function custom_css_js_enqueue_scripts() { | |
/* enqueue the custom-style.css file */ | |
wp_enqueue_style( 'custom-css', plugins_url( '/css/custom-style.css', __FILE__ ), $ver = false ); | |
/* enqueue the custom-scripts.js file */ | |
wp_enqueue_script( 'custom-js', plugins_url( '/js/custom-scripts.js', __FILE__ ), $deps = array( 'jquery' ), $ver = false, $in_footer = true ); | |
} | |
add_action( 'wp_enqueue_scripts', 'custom_css_js_enqueue_scripts' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment