Forums / General Questions / How to display state abbreviation in admin customer orders instead of whole name?

How to display state abbreviation in admin customer orders instead of whole name?

Locked

Started by tj1 on 27 Apr 2007, 3:03 AM · Views: 3,477

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
27 Apr 2007, 3:03 AM
#1
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

How to display state abbreviation in admin customer orders instead of whole name?

Hi, I would like to display shipping and billing address in the orders details with the standard state abbreviation instead of the whole state name.

Does anyone know what I need to change? I think I have to edit something in the admin/orders.php file, I'm just not sure what.

Thanks.

6 Dec 2007, 7:37 PM
#2
gl330k avatar

gl330k

New Zenner

Join Date:
Jul 2007
Posts:
24
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

I would also like to know this as well. Can someone post a solution for this?

I'm running zc 1.3.7

thanks

6 Dec 2007, 8:55 PM
#3
gl330k avatar

gl330k

New Zenner

Join Date:
Jul 2007
Posts:
24
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

Ok. I have an update actually. Is it possible to simply store the state value as the two-letter abbrev in the db? It doesn't matter what it looks like in the drop-down menu we just need the value in the db table to be AL instead of Alabama (for example).

If anyone knows a way how to do this please let me know.

thanks

11 Dec 2007, 7:28 PM
#4
smap avatar

smap

New Zenner

Join Date:
May 2006
Posts:
42
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

It's stored in the zones table as both full name (zones.zone_name) and abbreviation (zones.zone_code).

24 Nov 2008, 2:12 AM
#5
timonsk avatar

timonsk

New Zenner

Join Date:
Oct 2006
Posts:
14
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

OK, I'm probably missing something that is right in front of me.... This post seems to be asking what I'm looking for, but I still need the answer.

I too want to list the state abbreviation instead of the state name on the Invoice and Packing Slip. Would someone tell me what file(s), table, etc. that I need to change to make this happen? I see that there is a zone_code field that has the data I want displayed, but I don't know how/where to tell it to display.

Your help is greatly appreciated.

~Sharon :wacko:

24 Nov 2008, 2:21 AM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How to display state abbreviation in admin customer orders instead of whole name?

The address is built with the function zen_address_format ...

You would have to either customize that or, what I would do is add a paramater to the function that only the invoice and packing files pass to it as true and alter the way the state is displayed so not to mess up other things ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

24 Nov 2008, 3:02 AM
#7
timonsk avatar

timonsk

New Zenner

Join Date:
Oct 2006
Posts:
14
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

I'm definitely a baby zenner. Would you guide me more specifically?

Ajeh:

The address is built with the function zen_address_format ...

Where is that function?

Ajeh:

I would do is add a paramater to the function that only the invoice and packing files pass to it as true and alter the way the state is displayed so not to mess up other things ...

I know it is in English, but I don't have a clue where to start if I were going to do this. What files, tables, etc. should I be looking at?

Thank you and I apologize for my lack of knowledge. I search for hours to see if someone else had this same question answered and may have missed that as well.

~Sharon

24 Nov 2008, 3:25 AM
#8
timonsk avatar

timonsk

New Zenner

Join Date:
Oct 2006
Posts:
14
Plugin Contributions:
0

Re: How to display state abbreviation in admin customer orders instead of whole name?

Thank you for your help Ajeh. I continued searching and found this post http://www.zen-cart.com/forum/showthread.php?t=57057 that seems to have done what I was wanting.

~Sharon