function styles_autoload in Styles 6
Same name and namespace in other branches
- 6.2 styles.module \styles_autoload()
Autoload the Styles object classes when needed.
Parameters
string $class_name: The name of the registered class definition.
1 string reference to 'styles_autoload'
- styles_init in ./
styles.module - Implementation of hook_init().
File
- ./
styles.module, line 292 - Bundles similar display formatters together.
Code
function styles_autoload($class_name) {
if ($class_name == 'StylesDefault') {
module_load_include('inc', 'styles', 'includes/Styles');
}
else {
if ($class = styles_get_styles_class_by_class_name($class_name)) {
include_once $class['path'] . '/' . $class['file'];
}
}
}