Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

What does "enqueue" mean and what is the purpose of the wp_enqueue_style() function?

I am not sure I understand the purpose and meaning of this type of functions: wp_enqueue_style() and wp_enqueue_script().

2 Answers

Enqueue means to add (an item of data awaiting processing) to a queue of such items.

You can learn more about the function on the WP site: http://codex.wordpress.org/Function_Reference/wp_enqueue_style

but really it's just a safe way to add/enqueue a CSS style file to the wordpress generated page.

Thanks for the answer. I looked at that page before I even asked this here. Still, I am not sure I understand the relation between enqueuing and registering styles and scripts.