Re: Dynamic Price Updater
Updated file for download at http://chrome.me.uk/PriceUpdater.zip
There are 2 files included (/includes/modules/pages/product_info/)... jscript_updater.php and jscript_updater_new.php
The _new file includes the radio/checkbox capabilities and is currently very much in test mode... Delete the file you do not want to use then upload the one you do want to use and that's all
If you have downloaded a previous version and have it in place I recommend renaming the original file (j_script_updater.php is a good choice) then uploading the new file... This means if any issues arise restoring the original configuration should be easy
For clarification, at this point there are 2 known issues: Doesn't work for items on sale; Doesn't identify multiple cart additions... These are in the pipeline
Any feedback or bug reports would be greatly appreciated
Dan
Re: Dynamic Price Updater
I've posted (yet another) update for this mod (http://chrome.me.uk/PriceUpdater.zip) which can be seen working at http://chrome.me.uk/shopdev/
Hopefully I've fixed a few problems (most likely created a few more)... The Updater can now work with [some] sales and is quantity-aware
Prices will take into account the quantity the user has specified and adjust themselves accordingly... The quantities can be displayed in the main price header and the sidebox (these can be switched on or off independently)... Read the included readme for more information or post here if what I've written doesn't make sense :smile:
The Updater should now be aware of all radio/checkboxes
Also I've updated so that, hopefully, the currency shouldn't be an issue
Yet again, all feedback and bug reports are very much appreciated and I thank you all for your patience
Dan
Re: Dynamic Price Updater
Not keen on Priced by Attribute ... :cry:
The Gift Certificates with attributes is a good example ...
Re: Dynamic Price Updater
Quote:
Originally Posted by
Ajeh
Not keen on Priced by Attribute ... :cry:
The Gift Certificates with attributes is a good example ...
Interesting point there because the product is listed as starting at 5 then the 1st attribute says 5 (+5)
To my mind the first attribute should be 5 (+0) as nothing is being added to the base price... Second attrib would then be 10 (+5), 15 (+10) etc.
That's how I coded Updater to function (technically, the Updater finds 2 values but offers precedence to the value in parantheses for the above reason)
at http://chrome.me.uk/shopdev/index.ph...products_id=36 the base price is adjusted but no price adjustment (from base) is listed
I have to admit I'm hazy on the attributes and GVs so I've based the logic model on what I've seen
If I've got it a bit wrong I will recheck my regex's and release a new version :smile:
Cheers for the feedback!
Dan
Re: Dynamic Price Updater
The Priced by Attribute is usually products_price 0.00 where the lowest price of each Option Name(s) Option Value is used to make the base price ...
Probably that product should be done without the prefixes on the attributes to avoid visual confusion ... :smile:
Re: Dynamic Price Updater
Quote:
Originally Posted by
Ajeh
The Priced by Attribute is usually products_price 0.00 where the lowest price of each Option Name(s) Option Value is used to make the base price ...
Probably that product should be done without the prefixes on the attributes to avoid visual confusion ... :smile:
Incidentally, the removal of visual confusion would also fix the Updater... It uses the +, - or lack of prefix as the definitions of how the value should be handled
I just threw the default products included with the installation in there so I had something to work with
I'll do some more investigating and strengthen some of the routines
Thanks!
Dan
Re: Dynamic Price Updater
That could run into issues ...
Some sites use the + or blank for add and the only guarantee on a prefix is where - means subtract ...
Again we run into the visual issue here ... :blink:
This is one of the reasons the IF on attributes was switched way back in v1.x to be if negative do this otherwise do that ... so the default would be add ...
Re: Dynamic Price Updater
Ah
So it seems the Updater is doomed to only work with some installations
Without being able to rely on the prefix, and owing to the way it works, the Updater can never be guaranteed to be stable
Oh well, it was a nice idea... I'll leave the file in place so people can try it to see if it works for them... I'll continue to offer support here and additions if anyone wants them
Dan
Re: Dynamic Price Updater
Bet this means you don't want me to even mention TEXT attributes charged by letter or word, eh? :lamo:
Ain't if fun to be a coder?! :blink:
Re: Dynamic Price Updater
Aha! I'd spotted the text attributes and was scratching my head for a theory... I had half of one but hey lol
Yep coding is ace :smile: lol
Dan