function node_gallery_init in Node Gallery 6.3
Same name and namespace in other branches
- 6 node_gallery.module \node_gallery_init()
- 6.2 node_gallery.module \node_gallery_init()
Implements hook_init().
File
- ./
node_gallery.module, line 39 - Node gallery module file.
Code
function node_gallery_init() {
drupal_add_css(drupal_get_path('module', 'node_gallery') . '/node_gallery.css');
// Use the administrative theme if the user is looking at the upload page
// and has "use admin theme while editing content" enabled
// @todo: We should document this as a FAQ for people with themes that don't work with plupload.
if (variable_get('node_admin_theme', '0') && arg(0) == 'node' && (arg(2) == 'upload' || arg(2) == 'images' || arg(2) == 'sort')) {
global $custom_theme;
$custom_theme = variable_get('admin_theme', '0');
drupal_add_css(drupal_get_path('module', 'system') . '/admin.css', 'module');
}
}