New Zenner
- Join Date:
- Sep 2007
- Posts:
- 14
- Plugin Contributions:
- 0
Fixed Rate for light carts
How do I get the fixed rate NOT to appear as a choice for carts over 2 pounds.?
New Zenner
Sensei
if ($check_flag == false) {
$this->enabled = false;
}
}
if ($_SESSION['cart']->show_weight() > 2) $this->enabled = false;
}
// class methods
function quote($method = '') {New Zenner
Totally Zenned
New Zenner
yellow1912:
Actually DrByte said it clear enough, read everything very carefully. If you still don't know what to do, you will have to get someone do it for you (a friend, or some freelancer)
New Zenner
DrByte:
You'll have to edit code.
/includes/modules/shipping/flat.php
around line 55, you'll see this section. Add the line as shown:if ($check_flag == false) { $this->enabled = false; } } if ($_SESSION['cart']->show_weight() > 2) $this->enabled = false; } // class methods function quote($method = '') {
Totally Zenned
New Zenner
yellow1912:
Check if this file exists:
admin/includes/functions/general.php
Reuploaded it if needed.
New Zenner
yellow1912:
Check if this file exists:
admin/includes/functions/general.php
Reuploaded it if needed.
New Zenner
Sensei
Where did you get your usps.php shipping module from?JTCasinoGames:
/shop/includes/modules/shipping/usps.php on line 56
JTCasinoGames:
Fatal error: Call to a member function on a non-object in /hsphere/local/home/jtcasino/jtcasinogames.com/shop/includes/modules/shipping/usps.php on line 120
New Zenner
DrByte:
Where did you get your usps.php shipping module from?
What's *on* line 56 of that file?
If you turn off the USPS module, do things work properly?
What's on line 120 ?
In the master version of this module, those lines aren't trying to load any other files, and they aren't attempting to use external objects.
So, you've got something messed up in that file.
Furthermore, the code edit I offered you earlier has nothing to do with USPS, "and making that change *only in the file I instructed* shouldn't have any effect on USPS.
Sensei
JTCasinoGames:
... Also, even if I try to put it on the flat.php (flat rate shipping), it's throwing the same error "
New Zenner
DrByte:
What does he mean by "put it on the flat.php" ?
And does "throwing the same error" mean it's *exactly* the same, or just similar? Post the new error.
Sensei
Please post line 120 of that file. In fact, please zip up that file and post it as an attachment here.JTCasinoGames:
in zen cart when you select, modules then shipping we got:
Fatal error: Call to a member function on a non-object in /hsphere/local/home/jtcasino/jtcasinogames.com/shop/includes/modules/shipping/usps.php on line 120
It doesn't make any sense that the code would reference any admin files from the storefront. This suggests some odd customizations to your shipping module. Posting the file, as mentioned above, may help figure out what's happening.JTCasinoGames:
on the website, when the customer opened the shipping estimator AND when they went to checkout, it showed the error:
Warning: usps([B]../admin/includes/functions/general.php): failed to open stream: No such file or directory in /hsphere/local/home/jtcasino/jtcasinogames.com/shop/includes/modules/shipping/usps.php on line 56
[/B]
New Zenner
DrByte:
Please post line 120 of that file. In fact, please zip up that file and post it as an attachment here.
It doesn't make any sense that the code would reference any admin files from the storefront. This suggests some odd customizations to your shipping module. Posting the file, as mentioned above, may help figure out what's happening.
By what method are you implementing code changes? Do you edit on a PC and then upload the changes via FTP? Which editor?
Or are you editing directly on the website with some sort of tool? Which tool?
Sensei
New Zenner
New Zenner
New Zenner
Destination thread ID and reason are required when shown.
Tell staff why this post should be reviewed.
Required for login, security, and core site functionality.
Help us understand how the site is used so we can improve it.
Used for promotion and personalized campaign measurement.