Всем здравствуйте!
Помогите пжс с файлом template.php, слетел от вируса наверно из за этого сайт не грузиться, а просто белый фон, в логах пишет в 65 строке.
П.С. Я просто не знаю PHP
Благодарность гарантирую.
<?php
// $Id: template.php,v 1.4.2.1 2007/04/18 03:38:59 drumm Exp $
/**
* Sets the body-tag class attribute.
*
* Adds 'sidebar-left', 'sidebar-right' or 'sidebars' classes as needed.
*/
function phptemplate_body_class($sidebar_left, $sidebar_right) {
if ($sidebar_left != '' && $sidebar_right != '') {
$class = 'sidebars';
}
else {
if ($sidebar_left != '') {
$class = 'sidebar-left';
}
if ($sidebar_right != '') {
$class = 'sidebar-right';
}
}
if (isset($class)) {
print ' class="'. $class .'"';
}
}
/**
* Return a themed breadcrumb trail.
*
* param $breadcrumb
* An array containing the breadcrumb links.
* return a string containing the breadcrumb output.
*/
function phptemplate_breadcrumb($breadcrumb) {
if (!empty($breadcrumb)) {
return '
';
}
}
/**
* Allow themable wrapping of all comments.
*/
function phptemplate_comment_wrapper($content, $type = null) {
static $node_type;
if (isset($type)) $node_type = $type;
if (!$content || $node_type == 'forum') {
return '
';
}
else {
return '
'. t('Comments') .'
'. $content .'
';
}
}
function _phptemplate_variables($hook, $vars) {
$vars = array();
$css = drupal_add_css();
unset($css['all']['module']['modules/system/system.css']);
unset($css['all']['module']['modules/system/defaults.css']);
$vars['styles'] = drupal_get_css($css);
if ($hook == 'page') {
}
}
return $vars;
} !!!вот это здесь где то!!!
/**
* Override or insert PHPTemplate variables into the templates.
function _phptemplate_variables($hook, $vars) {
if ($hook == 'page') {
if ($secondary = menu_secondary_local_tasks()) {
$output = '';
$output .= "
- \n". $secondary ."
\n";
$vars['tabs2'] = $output;
}
// Hook into color.module
if (module_exists('color')) {
_color_page_alter($vars);
}
return $vars;
}
return array();
}
*/
/**
* Returns the rendered local tasks. The default implementation renders
* them as tabs.
*
* ingroup themeable
*/
function phptemplate_menu_local_tasks() {
$output = '';
if ($primary = menu_primary_local_tasks()) {
$output .= "
- \n". $primary ."
\n";
}
return $output;
}
function ds_search_theme_form(&$form) {
$form['submit']['#value']='';
$form['search_theme_form_keys']['#value'] = 'Поиск';
$form['search_theme_form_keys']['#attributes'] = array(
'onblur'=> "if (this.value.length == 0) {this.value='{$form['search_theme_form_keys']['#value']}'}",
'onfocus'=> "if (this.value== '{$form['search_theme_form_keys']['#value']}') {this.value=''}"
);
return drupal_render($form);
}
Комментарии
это в этом кусочке
<?php
if ($hook == 'page') {
} <----- лишняя скобка
}
return $vars;
}
?>
Спасибо большое.