WordPress file queue

From Wiki @ Karl Jones dot com
Jump to: navigation, search

In WordPress, the WordPress file queue is how WordPress loads files for external CSS and JavaScript.

Description

Files must be added to the queue in order for WordPress to use them.

The queue has an order: first file, second file, etc.

Dependencies

Often files have dependencies.

Example: File A must appear before File B.

We say that "A is a dependency of B", or "File B is dependent on File A".

This can go further: A is dependency of B, B is a dependency of C, etc.

It can also happen that a file is dependent on two or more other files.

Adding files to queue

Add files to the queue using the wp_enqueue_style() function.

See WordPress custom style sheet for an example of adding a custom CSS file into the queue.

See also

External links