I don't use Edit Orders.
Printable View
I don't use Edit Orders.
Note that this change to ajax.php
https://github.com/zencart/zencart/b...7/ajax.php#L51
only allows alpha-numeric characters/does not allow an underscore in either of the parameters.
So this call from DPU gets failed:
https://yoursite/ajax.php?act=DPU_Aj...hod=getDetails
as can be seen on the browser console network XHR with the 400 responses.
A quick fix is add the underscore to the check
but the class/use of this variable needs to be renamed.Code:!preg_match('/^[a-zA-Z0-9_]+$/', $_GET['act'])
Since DPU needs to taken behind the shed to be shot/replaced with this add-on to the core attributes stock manager
https://vinosdefrutastropicales.com/...products_id=60
I'm just giving a heads-up.
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:
toPHP Code:
if ($this->dpu->sideboxActive) {
And change \includes\templates\bootstrap\jscript\jscript_dynamic_price_updater.php, line 79 from:PHP Code:
if ($this->dpu->sideboxActive ?? FALSE) {
toPHP Code:
const DPUsideboxActive = ('<?php echo $dpu->sideboxActive; ?>' === '1');
I do not like these, but not sure where to go about declaring the property.PHP Code:
const DPUsideboxActive = ('<?php echo $dpu->sideboxActive ?? NULL; ?>' === '1');
Can anyone confirm if the GitHub version of the Dynamic Price Updater v5 (linked below) is compatible with Zen Cart 2.10?
https://github.com/dbltoe/Zen-Cart-D...-Price-Updater
I'm encountering an issue where the price is not updating, and the browser console logs a 400 Bad Request error for the AJAX call.
I noticed that I had the same issue as described in the last post of this thread by retched. I applied the two suggested edits, which resolved that specific problem, but the 400 Bad Request error persists.
Any insights or confirmation on compatibility would be greatly appreciated!
Thanks in advance!
The 'quick fix' in this post fixed the 400 error for me in v2.1.0. I have not (needed to) apply the two suggested edits.