Все доброго времени суток! Подскажите, кто силён.
В логах вылезает вот такая ошибка:
PHP Fatal error: Cannot redeclare comment_page_title_alter() in /home/u12028/domains/mysite.ru/sites/all/modules/page_title/modules/comment.page_title.inc on line 12, referer: http://mysite.ru/admin/modules
Что ему не нравится?
В файле код начиная с 12 строки:
function comment_page_title_alter(&$title) {
// Get the current menu item and compare the path to the comment reply path.
$menu_item = menu_get_item();
if ( !strncmp($menu_item['path'], 'comment/reply/%', 15) &&
($node = menu_get_object('node', 2)) ) {
// If the node has a custom page title and the node type is configured
// to have a custom page title (ie, it's not a leftover from a previous
// setting), then use it.
if ( !empty($node->page_title) &&
variable_get('page_title_type_' . $node->type . '_showfield', 0) ) {
$title = $node->page_title;
}
// Get the current menu item and compare the path to the comment reply path.
$menu_item = menu_get_item();
if ( !strncmp($menu_item['path'], 'comment/reply/%', 15) &&
($node = menu_get_object('node', 2)) ) {
// If the node has a custom page title and the node type is configured
// to have a custom page title (ie, it's not a leftover from a previous
// setting), then use it.
if ( !empty($node->page_title) &&
variable_get('page_title_type_' . $node->type . '_showfield', 0) ) {
$title = $node->page_title;
}
Комментарии
И ещё вопросик, может ли эта ошибка негативно отражаться на поиске сайта? Полез ошибки смотреть, потому что не работает поиск по сайту по node. Поиск по пользователю работает. Крон работает, индексация сайта 100%.
Похоже вот обсуждение этой ошибки https://www.drupal.org/node/1024624
спасибо, буду смотреть.
советую почитать это https://www.drupal.org/node/72099