Error.php mal géré

Error.php mal géré was created by nilegoff

Posted 5 years 7 months ago #49046
Bonjour,

En V4, il semble que le fichier error.php ait un problème d’accès à la configuration du template car
Code:
if ($this->params->get('useresponsive','1'))
est en erreur ainsi que
Code:
if ($this->params->get('googleanalyticscode',''))

Merci par avance pour votre aide.
Nicolas
Last Edit:5 years 7 months ago by nilegoff
Last edit: 5 years 7 months ago by nilegoff.

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic Error.php mal géré

Posted 5 years 7 months ago #49050
salut
chez moi il n'y a pas de souci avec cela. J'ai vu d'autres soucis dans la page d'erreur, mais pas cela.
Qu'as-tu comme message d'erreur qui te permet d'identifier que ce code a un souci ?
CEd

Joomlack Webmaster and Developer

by ced1870

Please Log in or Create an account to join the conversation.

Replied by nilegoff on topic Error.php mal géré

Posted 5 years 7 months ago #49051
Bonjour,

J'ai comme message d'erreur:
Notice: Undefined property: Joomla\CMS\Document\ErrorDocument::$params in /home/XXXXX/XXXXX/www/templates/fpsmv2/error.php on line 46

Fatal error: Call to a member function get() on null in /home/XXXXX/XXXXX/www/templates/fpsmv2/error.php on line 46

Ligne 46 j'ai:
Code:
if ($this->params->get('useresponsive','1'))

Merci de votre avis.
Nicolas

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic Error.php mal géré

Posted 5 years 7 months ago #49052
normalement au début du fichier error.php tu dois avoir
Code:
$this->params = $app->getTemplate(true)->params;

Joomlack Webmaster and Developer

by ced1870

Please Log in or Create an account to join the conversation.

Replied by nilegoff on topic Error.php mal géré

Posted 5 years 7 months ago #49053
Désolé,

Je n'ai pas cela au de but du code.

Je viens de rajouter
Code:
$app = JFactory::getApplication(); $this->params = $app->getTemplate(true)->params;

Maintenant j'ai pour erreur

Notice: Undefined variable: doc in /home/XXXX/XXXX/www/templates/fpsmv2/error.php on line 126
Fatal error: Call to a member function getBuffer() on null in /home/XXXX/XXXX/www/templates/fpsmv2/error.php on line 126


Code ligne 126:
Code:
<?php echo $doc->getBuffer('modules', 'top1', array('style' => 'htmlck')); ?>

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic Error.php mal géré

Posted 5 years 7 months ago #49054
tu as
Code:
$doc = JFactory::getDocument();
?
c'est bizarre, tu utilises bien la 4.0.8 (maintenant 4.0.9) de template creator ?

Joomlack Webmaster and Developer

by ced1870

Please Log in or Create an account to join the conversation.

Time to create page: 0.654 seconds

Fast and powerful creation, customizable and responsive.

Read More

We have 851 guests and one member online