Originally Posted by
mlankeit
First, some clarification... The Priority Handling module works by adding a new class to Zen Cart, called "ot_priority_handling", which encapsulates the processing or code portion that makes the module work. But the class itself does not store anything. The handling the handling charge itself and any preferences are stored in the ZenCart configuration table in MySQL. During a live cart session, whether the user selects this option or not is stored in the $_SESSION variable. Outside of this, the class then uses $_SESSION to see whether to do any processing; if so, then it uses the stored preferences to come up with a value to charge, does the tax calculation appropriately, and finally whatever else so everything shows up correctly in the final order total.
I supposed you could modify the built-in shipping module to accomplish something similar. I'm not sure why this would be preferable. If you want to add a flat-rate shipping charge base, just define your shipping preferences this way. The additional charge would be there, but it would be hidden. If you want to call out the charge specifically and give the user the option to add it or not, then you can use something like Priority Handling, and maybe just modify the language file so the text description is what you want. Therefore, I do not see any semantic reason for modifying the built-in shipping module code, but maybe I don't understand your specific application.
Another thing to consider is that modifying the built-in shipping module changes a component of the base distribution. The main idea with the Priority Handling module is to make the functionality an add-on that does not alter the distribution code base. Therefore, any Zen Cart update would be much easier for you using this module versus you trying to re-apply whatever code changes you did before on the base distribution.
Hope this helps. Good Luck!
-ml
Bookmarks