
Originally Posted by
retched
ZC 2.1.0 / PHP 8.3 / Using ZCABootstrap as template.
Managed to get everything to work by using the version loaded in from the GitHub, but changing attribute options on a product page, I get the following error:
Code:
[03-Dec-2024 22:50:55 America/New_York] Request URI: /justuptown/ajax.php?act=DPU_Ajax&method=getDetails, IP address: 127.0.0.1, Language id 1#0 E:\xampp\htdocs\justuptown\includes\classes\ajax\zcDPU_Ajax.php(110): zen_debug_error_handler()
#1 E:\xampp\htdocs\justuptown\ajax.php(77): zcDPU_Ajax->getDetails()
--> PHP Warning: Undefined property: DPU::$sideboxActive in E:\xampp\htdocs\justuptown\includes\classes\ajax\zcDPU_Ajax.php on line 110.
[03-Dec-2024 22:50:55 America/New_York] Request URI: /justuptown/ajax.php?act=DPU_Ajax&method=getDetails, IP address: 127.0.0.1, Language id 1
#0 E:\xampp\htdocs\justuptown\includes\classes\ajax\zcDPU_Ajax.php(110): zen_debug_error_handler()
#1 E:\xampp\htdocs\justuptown\ajax.php(77): zcDPU_Ajax->getDetails()
--> PHP Warning: Undefined property: DPU::$sideboxActive in E:\xampp\htdocs\justuptown\includes\classes\ajax\zcDPU_Ajax.php on line 110.
Okay... this is a bandaid, the errors have stopped but I fear this is only temporary:
include/classes/ajax/zcDPU_Ajax.php:
Change line about 110:
PHP Code:
if ($this->dpu->sideboxActive) {
to
PHP Code:
if ($this->dpu->sideboxActive ?? FALSE) {
And change \includes\templates\bootstrap\jscript\jscript_dynamic_price_updater.php, line 79 from:
PHP Code:
const DPUsideboxActive = ('<?php echo $dpu->sideboxActive; ?>' === '1');
to
PHP Code:
const DPUsideboxActive = ('<?php echo $dpu->sideboxActive ?? NULL; ?>' === '1');
I do not like these, but not sure where to go about declaring the property.