Closed (fixed)
Project:
Theme developer
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Reporter:
Created:
28 Mar 2012 at 09:54 UTC
Updated:
26 Jun 2012 at 10:01 UTC
hello,
I use this fuction in template.php function _phptemplate_variables($hook, $vars = array()) {
if ($hook == 'page' && isset($_GET['pop']) && $_GET['pop']) {
$vars['template_file'] = 'page-popup';
}
return $vars;
}
to change a specific page but still it displays page.tpl he no longer sees this function and it does not execute.
Thx for help
Comments
Comment #1
kenneth.venken commentedTry the THEME_preprocess_page(&$variables) function: http://api.drupal.org/api/drupal/includes!theme.inc/function/theme/7. Replace THEME with the name of your theme and place the function in your template.php file.
Add your custom template file to $variables['theme_hook_suggestions']. See http://drupal.stackexchange.com/questions/1501/page-template-suggestions... for more info.
Comment #2
kenneth.venken commented