Jump to content

canadian tax ID issues on the v5.1.2


tamouh

Recommended Posts

Hello,

 

We're planning to migrate from MBv4 to WHMCS v5.1.2.

 

I've noticed in the Setup -> Payments -> Tax Rules that I can select the Country and Province (Canadian) to assign for the tax code.

 

However, when a new client signs up or added, there is no drop down box to select that province. Often times customer will use variety of short names (like QC for Quebec or ON for Ontario) and this causes the tax code not to apply to the client.

 

I also found no way to add these short names manually. I had to go into the DB and add them one by one through phpMyAdmin.

 

Please advise...

 

Thanks,

 

Tamouh

Link to comment
Share on other sites

  • WHMCS Support Manager

Hi,

You can add a list of states for your country to the /includes/jscript/statesdropdown.js file and that will allow your clients to select one of the pre-defined sates from a dropdown. Just duplicate one of the existing lines, change it to "CA" and enter your states in the format of the existing entries.

 

This will solve the problem with them entering different variations of state names.

Link to comment
Share on other sites

This is an issue for those who are trying to process .ca domain registrations/transfers for Canadian customers.

 

The .ca registry rejects any submission that does not strictly conform to the standard Canadian province abbreviations.

 

For example:

 

Customer selects Province "Ontario" as part of their address information which then gets copied over to the domain registrant information. When the domain is submitted submitted to the registry it is rejected because it requires the province to be "ON".

 

You can update the statesdropdown.js file to show the abbreviations instead of full province names but then you break the tax calculation as noted in this post because ON does not map to Ontario in WHMCS so the taxes cannot be calculated because WHMCS does not recognize the province.

 

I'm currently working on a fix for this. When I come to a solution I will post it up.

Link to comment
Share on other sites

Ok, As John Mentioned add the Canadian Provinces to the /includes/jscript/statesdropdown.js file

 

Take out the existing states['CA'] line and add this:

 

states['CA'] = ["AB","BC","MB","NB","NL","NT","NS","NU","ON","PE","QC","SK","YT","end"];

 

If you've already setup your tax table you must update it so the names map and WHMCS can detect the correct province for your customers.

 

For example if one of your customers has their state/province set to "Ontario" in their profile you now need to change that to "ON" for the tax to apply accordingly. Also make sure that you update the state field in tbltax to "ON" rather than "Ontario" if you have already setup your tax items, or just delete them and re-add them.

 

If you need to batch convert your customer fields you can run some SQL like this on your WHMCS database for each province:

 

UPDATE tblclients SET state='ON' WHERE state='Ontario' AND country='CA'

 

Do this for each province. Good Luck!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated