Zen Cart Logo
Forums / Addon Order Total Modules / help with changing a few things?

help with changing a few things?

Views: 9,319

Results 1 to 20 of 32
16 Jan 2026, 12:57 PM
#1
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

help with changing a few things?

zen 2.10 php 8.3
how would i go about changing this module to check by manufacturer or category?
https://www.zen-cart.com/downloads.php?do=file&id=1407
i had to change a few things to make it work in 2.10.
there are a few of my distributors that are now charging a tarrif fee to their products and i need to add this fee to website, i found the ot_extraorderfee module but need it to check by manufacturer. can anyone help me with this?

16 Jan 2026, 4:31 PM
#2
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

It was good to see the name Ajeh again. I followed her from osCommerce to Zen Cart 22 years ago.

She did a lot to get us to today. However, standards change just as my hair turned white and thinned even more.

I haven't had a chance to really test the changes I needed make to the files. I know the language file now meets standards and the ot_extraorderfee.php is compliant through PHP 8.4. However, I have not verified the database operations in the file.

When I have more time, I will verify and submit the update.

Use at your own risk, backup, backup, backup.

[Attachment no longer available]

17 Jan 2026, 1:19 PM
#3
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

getting this. ```
PHP Fatal error: Uncaught Error: Undefined constant "MODULE_ORDER_TOTAL_EXTRAORDERFEE_SORT_ORDER" in /includes/modules/order_total/ot_extraorderfee.php:33

but, this does not address my issue, i need away to only show with certain categories and only charge for those categories.
17 Jan 2026, 1:55 PM
#4
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

It was a quick attempt to get it to 2.#.# and then look at being selective.

I hope to get back to it later today.

17 Jan 2026, 3:06 PM
#5
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

Had a break in the action.

Again, use at your own risk and back everything up first.

https://github.com/dbltoe/extraorderfee

17 Jan 2026, 3:21 PM
#6
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

still did not let me install, got same error again, but i changed line to this and now working

$this->sort_order = (defined('MODULE_ORDER_TOTAL_EXTRAORDERFEE_SORT_ORDER')) ? MODULE_ORDER_TOTAL_EXTRAORDERFEE_SORT_ORDER : null;

oh and thank you

17 Jan 2026, 3:26 PM
#7
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

ok 1 more thing, what if different manufacturers charge a different percent. example manufacturer a charges a tariff of 8% and manufacturer b charges 10%
how can we (you) add that, or would copying module work?

17 Jan 2026, 3:29 PM
#8
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

matbe like wholesale pricing works comma seperated percents in the percent field?

17 Jan 2026, 3:29 PM
#9
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

You're welcome.

You are able to apply it to Manufacturers, Categories, etc as needed? If so, I'll update GitHub and submit to the forum.

17 Jan 2026, 3:42 PM
#10
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

jimmie:

ok 1 more thing, what if different manufacturers charge a different percent. example manufacturer a charges a tariff of 8% and manufacturer b charges 10%
how can we (you) add that, or would copying module work?

I can see where that would be useful. I think it would be better like quantity discounts:

Where

A 8%
B 10%

With A being ID 5 and B being ID 20

5:8,20:10

Do you think the same would be needed for categories? I would think the same as the Manufacturers

17 Jan 2026, 3:47 PM
#11
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

ok after testing, i activate module, trying to use as is, No manufacturers or categories choosen i get error when going to shopping cart, error does not display

17 Jan 2026, 3:53 PM
#12
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

dbltoe:

I can see where that would be useful. I think it would be better like quantity discounts:

Where

A 8%
B 10%

With A being ID 5 and B being ID 20

5:8,20:10

Do you think the same would be needed for categories? I would think the same as the Manufacturers

my situation is manufacturer a everthing they carry has a tarriff of 8% manufacturer b has a tarriff of 10% only on their cabinet lines everthing else they carry is normal

17 Jan 2026, 3:55 PM
#13
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

Anything is possible with a lack of sleep from another project. :(

I don't know if I'll have time to create a test site and check it our but what do you mean by > No manufacturers or categories choosen i get error when going to shopping cart

500?

17 Jan 2026, 3:58 PM
#14
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

dbltoe:

Anything is possible with a lack of sleep from another project. :(

I don't know if I'll have time to create a test site and check it our but what do you mean by

500?

meaning just activating module and not choosing the new stuff you put in and just trying to activate it sitewide
WARNING: An Error occurred, please let us know!

17 Jan 2026, 3:59 PM
#15
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

error does not display in admin

17 Jan 2026, 4:03 PM
#16
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

Does the browser mention a 500 error or simply the WARNING: An Error occurred, please let us know!

17 Jan 2026, 4:07 PM
#17
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

Also, when it failed with no settings for Manufacturer or Category, did you have a percentage set? If you did not, it should fail. If you did, it should have applied the percentage to everything.

17 Jan 2026, 4:43 PM
#18
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

just got the warning, and tried with and without a percentage

3 Feb 2026, 8:50 PM
#19
jimmie avatar

jimmie

Totally Zenned

Join Date:
Jan 2013
Location:
New Port Richey, Florida
Posts:
971
Plugin Contributions:
0

Re: help with changing a few things?

Have u had a chance to see what is wrong?

4 Feb 2026, 3:57 AM
#20
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,806
Plugin Contributions:
15

Re: help with changing a few things?

Sorry, I'm swamped with work.