![]() |
XCart 5 - Enable/Disable Shipping & Payment Methods Based On Country Selected
I want to decide at run time during country selection, to show only my shipping method for limited countries and disable rest of the shipping methods, even if they are suppose to be shown for countries conflicting with my plugin.
E.g. My plugin is enabled for USA, GBR. Then in that case only my shipping and payment methods should be shown for those countries and rest of all the shipping and payment methods should be disabled. Please let me know how to go about it |
Re: XCart 5 - Enable/Disable Shipping & Payment Methods Based On Country Selected
Without testing, just taking a glance at the code, it looks like the template is default/en/shipping_list.tpl
In that template I see {foreach:getRates(),rate} I believe I see this getRates() method defined in XLite\View\ShippingList.php There may be a more elegant solution, but my starting point would be to attempt to expand the logic of this getRates() method. Right now it is a simple return, we could start modifying it like this (psuedocode warning): Code:
protected function getRates() Again, this is just a quick look, not sure if these files or methods are even related to your task! -Mike |
All times are GMT -8. The time now is 08:42 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.