queue_css_url — Add a CSS file to the current page by URL.¶
Summary¶
- queue_css_url($url, $media = 'all', $conditional = false)¶
Add a CSS file to the current page by URL.
The stylesheet link will appear in the head element. This needs to be called either before head() or in a plugin_header hook.
Parameters: - $url –
- $media (string) – CSS media declaration, defaults to ‘all’.
- $conditional (string|bool) – IE-style conditional comment, used generally to include IE-specific styles. Defaults to false.
Usage¶
Examples¶
Use to load in external stylesheets, such as Google Fonts. Add link to page head using head_css():
<?php queue_css_url('http://fonts.googleapis.com/css?family=Raleway:400,600'); ?>
<?php head_css(); ?>