As the name goes, wp_enqueue_style() will queue and then print out your plugin’s CSS link.
in the theme footer (refer to the default theme footer.php if unsure). Many themes especially self-created ones has failed to include wp_head() in the header.php as well as wp_footer() in the footer.php. The default value of the last argument is false, which means it will load it in the header by default.
This new hook:
Note 1: When you use wp_enqueue_script(), it will automatically register the script and then print it out, whereas if you use wp_register_script(), you will have to manually print it out by calling wp_print_scripts().
Excellent tutorial, thanks Lester.
Comments are closed.