function jscalendar_available_styles in Javascript Tools 5
Search recursively for any CSS file.
1 call to jscalendar_available_styles()
- jscalendar_admin_settings in jscalendar/
jscalendar.module - Menu callback for admin settings.
File
- jscalendar/
jscalendar.module, line 89 - Provide popup calendar.
Code
function jscalendar_available_styles($dir = NULL) {
$path = drupal_get_path('module', 'jscalendar');
$files = file_scan_directory($path, '\\.css$');
foreach ($files as $file) {
if ($file->basename != 'jscalendar.css') {
if ($file->basename == 'theme.css') {
$file->name = str_replace(array(
$path . '/lib/skins/',
'/theme.css',
), '', $file->filename);
}
$jscalendar_styles[$file->filename] = $file->name;
}
}
return $jscalendar_styles;
}