Closed (works as designed)
Project:
Studio theme pack
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
27 May 2009 at 13:21 UTC
Updated:
27 May 2009 at 21:34 UTC
/**
* Implementation of hook_preprocess.
*
* Since it is difficult to properly determine the path of a theme and subthemes
* when the system is offline, the specific preprocess funtion for the
* maintenance_page hook is called directly.
*
* @param $vars
* @return Array
*/
function canvas_preprocess_maintenance_page(&$vars) {
$vars['body_attributes']['id'] = 'maintenance-page';
$vars['body_attributes']['class'][] = $vars['body_classes'];
$vars['attributes'] = theme('render_attributes', $vars['body_attributes']);
}
Why is this needed?
Comments
Comment #1
Zarabadoo commentedThis is to give id and classes to the maintenance page template. Unfortunately, preprocess does not seem to go through the same preprocess as other template files, so I had to separate it out.
Comment #2
jurriaanroelofs commentedoh, it's probably because
drupal_get_path('theme', 'canvas')doesn't work in offline mode right? Yeah that makes sense then. Thx.