function ctools_stylizer_add_css
Add the necessary CSS for a stylizer plugin to the page.
This will check to see if the images directory and the cached CSS exists and, if not, will regenerate everything needed.
File
-
includes/
stylizer.inc, line 75
Code
function ctools_stylizer_add_css($plugin, $settings) {
if (!file_exists(ctools_stylizer_get_image_path($plugin, $settings, FALSE))) {
ctools_stylizer_build_style($plugin, $settings, TRUE);
return;
}
ctools_include('css');
$filename = ctools_css_retrieve(ctools_stylizer_get_css_id($plugin, $settings));
if (!$filename) {
ctools_stylizer_build_style($plugin, $settings, TRUE);
}
else {
drupal_add_css($filename);
}
}