Diverse Smarty-Fehler nach Update

Hallo,

nach dem Update von 6.4.1 auf 6.5.3 (Wunsch des Kunden) zeigen sich diverse Smarty-Fehler.

Hat sich Smarty dadurch auch geändert?
Wie kann man die Smarty-Version auslesen?

Viele Grüße Thoni

Hier ist ein Beispiel:

[2024-01-02 10:23:03] OXID Logger.ERROR: count(): Argument #1 ($value) must be of type Countable|array, null given [“[object] (TypeError(code: 0): count(): Argument #1 ($value) must be of type Countable|array, null given at /www/htdocs/x123456/oxid/source/tmp/smarty/dee492f32d638ffdab3c9c06e33609f2^%%28^28D^28DEE24D%%errors.tpl.php:3)\n[stacktrace]\n#0 /www/htdocs/x123456/oxid/vendor/smarty/smarty/libs/Smarty.class.php(1875): include()\n#1 /www/htdocs/x123456/oxid/source/tmp/smarty/dee492f32d638ffdab3c9c06e33609f2^%%36^366^366ECF91%%page.tpl.php(64): Smarty->_smarty_include(Array)\n#2 /www/htdocs/x123456/oxid/vendor/smarty/smarty/libs/Smarty.class.php(1875): include(‘/www/htdocs/w01…’)\n#3 /www/htdocs/x123456/oxid/source/tmp/smarty/dee492f32d638ffdab3c9c06e33609f2^%%40^405^405277AF%%start.tpl.php(129): Smarty->_smarty_include(Array)\n#4 /www/htdocs/x123456/oxid/vendor/smarty/smarty/libs/Smarty.class.php(1269): include(‘/www/htdocs/w01…’)\n#5 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Internal/Framework/Smarty/Legacy/LegacySmartyEngine.php(66): Smarty->fetch(‘page/shop/start…’, ‘ox|0|0|0|0|ssl’)\n#6 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Internal/Framework/Templating/TemplateRenderer.php(35): OxidEsales\EshopCommunity\Internal\Framework\Smarty\Legacy\LegacySmartyEngine->render(‘page/shop/start…’, Array)\n#7 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Core/ShopControl.php(509): OxidEsales\EshopCommunity\Internal\Framework\Templating\TemplateRenderer->renderTemplate(‘page/shop/start…’, Array)\n#8 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Core/ShopControl.php(359): OxidEsales\EshopCommunity\Core\ShopControl->_render(Object(OxidEsales\Eshop\Application\Controller\StartController))\n#9 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Core/ShopControl.php(282): OxidEsales\EshopCommunity\Core\ShopControl->formOutput(Object(OxidEsales\Eshop\Application\Controller\StartController))\n#10 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Core/ShopControl.php(142): OxidEsales\EshopCommunity\Core\ShopControl->_process(‘OxidEsales\\Esho…’, NULL, NULL, NULL)\n#11 /www/htdocs/x123456/oxid/vendor/oxid-esales/oxideshop-ce/source/Core/OXID.php(27): OxidEsales\EshopCommunity\Core\ShopControl->start()\n#12 /www/htdocs/x123456/oxid/source/index.php(16): OxidEsales\EshopCommunity\Core\OXID::run()\n#13 {main}\n”]

In Zeile 3 der XXXerrors steht:

<?php if (count ( $this->_tpl_vars['Errors'] ) > 0 && ( count ( $this->_tpl_vars['Errors']['default'] ) > 0 || count ( $this->_tpl_vars['Errors']['popup'] ) > 0 )): ?>

Ausgelöst wird der Fehler in dieser Zeile in der page.tpl:

[{include file=“message/errors.tpl”}]

Kann es an der PHP-Version liegen?
7.4.33 → 8.1.26

Flow? Das wäre dann ein bekannter Fehler. Du musst den Quelltext editieren und vor count () das Vorhandensein des Error-Arrays prüfen. Lösung findest mehrfach im Forum.

RoxIVE!

Vor dem Update funktionierte alles.

Roxive war die Basis für Flow, soweit ich das in Erinnerung habe.

Gib folgendes in die Suche ein:

$this->_tpl_vars[‘Errors’]

Das mit dem errors ist gefixt - danke.

Von der Sorte gibt es noch einige.

Wirkt sich der Fehler funktional aus oder taucht das nur im Log auf?