Вверх

Блог
RSS лента

Ответить на комментарий

warning: Parameter... comment_user(), pathauto_user(), block_user(), blog_user(), dblog_user(), locale_user(), node_user() и др.

Не буду по каждой предупреждению создовать новое сообщение, а просто приведу тут списочек ошибок и как их решить. По крайней мере то что на данный момент мне попалось на глаза.

Ошибка:
warning: Parameter 3 to comment_user() expected to be a reference, value given in .../includes/module.inc on line 450.

Решение:
Открываем файл:
/modules/comment/comment.module
ищем:
function comment_user($type, $edit, &$user, $category = NULL) {
Меняем на:
function comment_user($type, $edit, $user, $category = NULL) {

Ошибка:
warning: Parameter 2 to pathauto_user() expected to be a reference, value given in .../includes/module.inc on line 450.

Решение:
Открываем файл:
/modules/pathauto/pathauto.module
ищем:
function pathauto_user($op, &$edit, &$user, $category = FALSE) {
Меняем на:
function pathauto_user($op, $edit, $user, $category = FALSE) {

Ошибка:
warning: Parameter 3 to block_user() expected to be a reference, value given in .../includes/module.inc on line 450.

Решение:
Открываем файл:
/modules/block/block.module
ищем:
function block_user($type, $edit, &$account, $category = NULL) {
Меняем на:
function block_user($type, $edit, $account, $category = NULL) {

Путь к файлам может отличатся, Например модуль может находится здесь .../sites/all/modules/
Собственно таким вот методом лечим все варниги. То есть вам нужно смотреть на какую функцию друпал ругается, например block_user(), мы видим что это модуль block. Идем в одно именую папочку в папочке модулей и находим функцию в которой притаилась беда, в этом случае амперсанд который нужно просто удалить. Так же действуем и с другими функциями.

Ваша оценка: Пусто Средняя: 3 (125 votes)

Ответить

 
  • Адреса страниц и электронной почты автоматически преобразуются в ссылки.
  • Строки и параграфы переносятся автоматически.
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>. Beside the tag style "<foo>" it is also possible to use "[foo]".
  • Image links with 'rel="lightbox"' in the <a> tag will appear in a Lightbox when clicked on.
  • Image links from G2 are formatted for use with Lightbox2
  • Image links with 'rel="lightshow"' in the <a> tag will appear in a Lightbox slideshow when clicked on.
  • Links to HTML content with 'rel="lightframe"' in the <a> tag will appear in a Lightbox when clicked on.
  • Links to video content with 'rel="lightvideo"' in the <a> tag will appear in a Lightbox when clicked on.
  • Links to inline or modal content with 'rel="lightmodal"' in the <a> tag will appear in a Lightbox when clicked on.

Подробнее о форматировании

Главная | Портфолио | Услуги | Контакты | Блог