Regarding this, I'm thinking that will define as %s and then allow the DPU class and/or perhaps the script on the final page to provide substitution of the text through the use of the sprintf function.
Printable View
The debug log due to the missing constant DPU_OUT_OF_STOCK_IMAGEQuote:
what issue(s) are trying to be resolved?
I've rejigged that switch to check first for that constant, removed all these unnecessarysince this is part of the install.Quote:
defined('DPU_SHOW_OUT_OF_STOCK_IMAGE).
Then I was pondering over the logic of the section. I don't really get how the out of stock stuff should work/what it is trying to do and since I don't use it I won't be investing any more time in it.
Normally I would try and improve things but I have too much to do already. I think the readme could do with more info.
I stuck it in the class
includes/classes/dynamic_price_updater.php
PHP Code:
$this->responseText['stock_quantity'] = $this->product_stock;
define('DPU_OUT_OF_STOCK_IMAGE', '');//steve missing: https://www.zen-cart.com/showthread.php?70577-Dynamic-Price-Updater&p=1355225#post1355225
if (defined(DPU_OUT_OF_STOCK_IMAGE)) {
THANX
I put it in includes/languages/english/extra_definitions/dynamic_price_updater.php to maintain uniformity.
Hi
Is Dynamic Price Updater compatible with ZenCart 1.5.6?
Fourth time at trying to post this...
Yes and no. As reported recently in this thread, the version available here will likely throw a myDebug file for the lack of definition associated with stock quantities; however, version 3.2.1: https://github.com/mc12345678/Dynami...ter/tree/3.2.1 has (or should by now have) a definition included that displays quantities available associated with the product quantity lookup (meaning when using Stock By Attributes it should narrow down the available quantity based on selections made); however, it looks like if no selections have been made the initial stock message incorrectly identifies that the product is out of stock, but updates when selections have been made. I expect some alternate text to be displayed or the total quantity of the product, but either/both of those are dependent on how the store uses such quantities. Anyways, that feature can be turned off also to not cause confusion to the customer.
HI Mc
It works ok. I'm upgrading the live site tomorrow (I hope!) but I have a question: If say you go to https://sitstandforbusiness.com/fund...ent-p-113.html, We have the inc VAT price howing as well as the ex VAT price. However on the new version these get overriden by the Your Price and the unit price.
How can I prevent the inc/ex VAT prices being hidden and replaced with the Your Price? Please advise.
Sorry that do not have all of the details together yet; however, I did today go to that product and saw the spinning graphic did not replace the existing values, but instead was shown off to the side.
So, first things first, currently the module returns only one price, either with tax included or without tax included based on the settings for the display of price on the catalog side. Further, the returned price is expected to take the place of the associated product's price value based on identifying the id for the html parameter that is to hold that price. The implementation of the Includes/Excludes VAT that I saw on the site, also offers a separate identifier for the price that contains the Tax'd value. The DPU class could return two fields instead of just one to provide both the taxed and non-taxed value, with the javascript to process not only the returned value, but to also identify to what location it should be assigned (thought I remembered the module supporting display of the information in either sequence of non-taxed first with taxed to follow or vice versa). These additional "options" may introduce additional classes/ids of concern to handle in different ways... I know that at one point I had begun to incorporate the likes of that module or an older one, but other aspects of the software were more important and I had to put that aside at least as a solution for all versus incorporating a limited correction. Hope the launch is going well!
Hi MC
The live site at present hasn't been updated. Everything I am doing is on my test server.
Yes that's correct. And it does work when I updated this site to 1.55f but on the updated 1.5.6c the prices for Inc and Ex VAT show normally, then when the page is loaded, they are superseded by the Updater (was labelled At least, I renamed it price).
Yes that's exactly what the current site does and I would love to be able to recreate this for the new site. The launch is pretty much ready to go, except for this and a separate issue.
I hope you can help. :)