function _css_injector_rule_path in CSS Injector 6
Same name and namespace in other branches
- 7.2 css_injector.module \_css_injector_rule_path()
Helper function to get file path for a rule
5 calls to _css_injector_rule_path()
- css_injector_edit in ./
css_injector.admin.inc - Constructor for the CSS rule edit form.
- css_injector_edit_save in ./
css_injector.admin.inc - Submit button callback for the CSS rule edit form.
- css_injector_init in ./
css_injector.module - Implementation of hook_init(). Checks to see whether any CSS files should be added to the current page, based on rules configured by the site administrator.
- theme_css_injector_admin_form in ./
css_injector.admin.inc - Theme function for the CSS Injector admin overview form.
- _css_injector_delete_rule in ./
css_injector.module - Helper function to delete an existing rule and its accompanying file.
File
- ./
css_injector.module, line 170 - Allows administrators to inject CSS into the page output based on configurable rules. Useful for adding simple CSS tweaks without modifying a site's official theme.
Code
function _css_injector_rule_path($crid) {
if (!empty($crid)) {
$directory = file_directory_path();
return $directory . '/css_injector_' . $crid . '.css';
}
return NULL;
}