 | MEMBER LOGIN |
|
|
 |
|
 | SERVICES & FEATURES |
|
|
 |
|
 | THE 20 LATEST PROJECTS |
 | POPULAR NEW PROJECTS |
|
|
Project: Modification: Zen Cart cc.php ID: 1228158851 |
|  |  |  |
 |
| |
|
Status: |
Closed (Cancelled)
|
|
Budget: |
N/A
|
|
Created: |
12/1/2008 at 14:14 EST
|
|
Cancelled: |
12/23/2008 at 0:34 EST
|
|
Project Creator: |
|
|
Description: |
I need to be able to add a flag into the attached cc.php file so that if specified product IDs are found in the cart, the module won't show up. We want to disallow credit card payment only on specific items.
I've got this code which flags based on order total and it's supposed to make the module not show up if the order is under $15, which is similar but not exactly what we want. And it doesn't work so I don't know if it's helpful, but thought I'd include it in case it is:
// control by order total
$chk_order_total = $_SESSION['cart']->show_total() - $_SESSION['cart']->free_shipping_prices() ;
if ($this->enabled == true && $chk_order_total <= 15) {
$this->enabled = true;
} else {
$this->enabled = false;
}
The module itself has a section that checks for flags based on shipping zones and if certain zones are disabled it won't show up but I don't have that activated. That also might be helpful to base the code on.
All I need is a bit of code added there that I can specify which products the cc module should *not* show up for (or which it should, it doesn't matter either way I just need to specify by product ID when it either shouldn't or should appear during checkout). I can directly modify the cc.php file to add these product IDs so no admin interface needs programmed.
Please message with any questions. Thanks!
|
|
Job Type: |
PHP
|
| |
 |
|
Messages Posted: 11 |
| |