Zen Cart Logo
Forums / Managing Customers and Orders / Add tax id field to registration

Add tax id field to registration

Locked

Views: 7,030

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
4 Apr 2008, 3:31 PM
#1
lifeforce avatar

lifeforce

New Zenner

Join Date:
Apr 2008
Posts:
11
Plugin Contributions:
0

Add tax id field to registration

Hello,
I'm setting up a shopping cart for a wholesale company. It's generally the standard for wholesale sites to hide prices until an EIN or tax id number is input so that the retailer's customers wont see the wholesale prices. I've already set up the store to hide prices until a user is logged in, so now I just need to add a field to the registration.

I already can verify it (it would just be a matter of checking to make sure the string consists of 9 numbers), but I don't know which include has the registration form, or how to make it save that value in the database. Can anyone help with that?

4 Apr 2008, 6:16 PM
#3
lifeforce avatar

lifeforce

New Zenner

Join Date:
Apr 2008
Posts:
11
Plugin Contributions:
0

Re: Add tax id field to registration

Hmm, yeah, that warning does not inspire confidence. I'll look through it to try and understand where to add the fields if I have to, but being a general purpose plug in to add fields, it will probably be a lot of code to sort through (sort of like backwards engineering an entire f-16 to try and figure out how to make an ejector seat).

10 May 2008, 9:03 PM
#4
aporia avatar

aporia

New Zenner

Join Date:
Jun 2004
Posts:
4
Plugin Contributions:
0

Re: Add tax id field to registration

I also need to collect the EIN number from American customers to ship goods across the Canada/US border. After looking through the code with the Developers Tool Kit, I realized that adding this would require modifying many of the core php files and adding new fields to the database (as opposed to merely using the template overrides), but it didn't look too difficult.

So - I have added a Tax ID field to the address book, essentially allowing people to add it in with their company name.

This is the kind of modification that will likely break with the next release of Zen Cart and require re-modding (unless they incorporate the tax id into their plans) - but I will share it if anyone is interested.

Installing my upgrade will overwrite many files with the new ones, and I am not going to help anyone merge my changes in with other changes that may have been made... but let me know if you want me to upload this change...

Cheers

13 May 2008, 3:49 PM
#5
lifeforce avatar

lifeforce

New Zenner

Join Date:
Apr 2008
Posts:
11
Plugin Contributions:
0

Re: Add tax id field to registration

I think we ended up doing the same thing. I eventually just kept digging through every php file and mysql table I could that had the company name field in it and added info for the EIN number below it. It works fine now, but I had almost no idea what I was doing (I know php pretty well, but I don't understand Zen Cart's inner workings at all), and an upgrade would almost certainly break it (thankfully, v1.3.8 has nothing really tempting in it).