Skip to content

Instantly share code, notes, and snippets.

@duongthienit
Created July 30, 2018 10:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save duongthienit/e32d4145a166cd1d976cb02fb7c9d461 to your computer and use it in GitHub Desktop.
Save duongthienit/e32d4145a166cd1d976cb02fb7c9d461 to your computer and use it in GitHub Desktop.
function theme_styles() {
wp_enqueue_style( 'bootstrap_css', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css' );
wp_enqueue_style( 'main_css', get_template_directory_uri() . '/style.css' );
}
add_action( 'wp_enqueue_scripts', 'theme_styles');
function theme_js() {
global $wp_scripts;
wp_enqueue_script( 'bootstrap_js', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js');
wp_enqueue_script( 'my_custom_js', get_template_directory_uri() . '/js/scripts.js');
}
add_action( 'wp_enqueue_scripts', 'theme_js');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment