Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Where can I find zone-id?


bbyyaa

Recommended Posts

Hi,

 

Where can I find zone_id set up so it is passed to the $order->delivery['zone_id'] in include/module/vendor_shipping/ups.php?

I printed out the $order->delievery['zone_id'] for debugging purpose.

 

It seems to me that Hawaii is set up as 21, New York is set up as 43, Vermont is set up as 59 and so on?

I don't see it at the admin section.

 

Anyhow knows? Or any guessing?

Link to comment
Share on other sites

This is one way to find out.

 

Copy the text in the CODE box below:

 

<?php
 require('includes/application_top.php');

 $zones_query = tep_db_query("select zone_id, zone_name from " . TABLE_ZONES . " where zone_country_id = '" . (int)$customer_country_id . "' order by zone_name");
 while ($zones = tep_db_fetch_array($zones_query)) {
echo $zones['zone_id'] . ' ' . $zones['zone_name'] . '<br>';
 }
?>

Save it as zoneprnt.php, then upload to your catalog folder.

 

LOGIN TO YOUR OSC STORE.

 

Then in the browser address bar change the URL to yourstore.com/catalog/zoneprnt.php

 

The script will output all the zones for your country.

 

When I did it I got this:

 

1 Alabama

2 Alaska

3 American Samoa

4 Arizona

5 Arkansas

6 Armed Forces Africa

7 Armed Forces Americas

8 Armed Forces Canada

9 Armed Forces Europe

10 Armed Forces Middle East

11 Armed Forces Pacific

12 California

13 Colorado

14 Connecticut

15 Delaware

16 District of Columbia

17 Federated States Of Micronesia

18 Florida

19 Georgia

20 Guam

21 Hawaii

22 Idaho

23 Illinois

24 Indiana

25 Iowa

26 Kansas

27 Kentucky

28 Louisiana

29 Maine

30 Marshall Islands

31 Maryland

32 Massachusetts

33 Michigan

34 Minnesota

35 Mississippi

36 Missouri

37 Montana

38 Nebraska

39 Nevada

40 New Hampshire

41 New Jersey

42 New Mexico

43 New York

44 North Carolina

45 North Dakota

46 Northern Mariana Islands

47 Ohio

48 Oklahoma

49 Oregon

50 Palau

51 Pennsylvania

52 Puerto Rico

53 Rhode Island

54 South Carolina

55 South Dakota

56 Tennessee

57 Texas

58 Utah

59 Vermont

60 Virgin Islands

61 Virginia

62 Washington

63 West Virginia

64 Wisconsin

65 Wyoming

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

This is one way to find out.

 

Copy the text in the CODE box below:

 

<?php
 require('includes/application_top.php');

 $zones_query = tep_db_query("select zone_id, zone_name from " . TABLE_ZONES . " where zone_country_id = '" . (int)$customer_country_id . "' order by zone_name");
 while ($zones = tep_db_fetch_array($zones_query)) {
echo $zones['zone_id'] . ' ' . $zones['zone_name'] . '<br>';
 }
?>

Save it as zoneprnt.php, then upload to your catalog folder.

 

LOGIN TO YOUR OSC STORE.

 

Then in the browser address bar change the URL to yourstore.com/catalog/zoneprnt.php

 

The script will output all the zones for your country.

 

When I did it I got this:

Link to comment
Share on other sites

Hi Jim,

 

Thank you very very much.

My I ask another question? How does UPS determine the shipping options for certain states? How do they determine the ground transit time? For example, if the origin is NY, there will be 1 or 2 days for destination PA depending on east PA or west PA.

My main question, is there any way to cut down some shipping options just for certain states instead of accepting all options from UPS?

Do you know the answer or any guessing? Thanks again for the zone id solution.

Link to comment
Share on other sites

I don't know how UPS works in osC.

 

I did hear on the news today that Fed-Ex is buying out UPS.

 

When they merge they're going to change the company name to Fed-UP.

(snicker snicker)

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...