Jump to content

How to group countries into regions?


theITvideos

Recommended Posts

I am working on a site, on a shipping profile module that requires users to group the countries into regions to ship the items to. That is:

 

Region 1 - Japan, USA, Spain, Italy.

Region 2 - Belgium, France, Germany.

 

I have a table that has all the Country names which will be populated in a Listbox control for users to select.

 

Once the supplier has selected a group of countries from the Listbox, how can I properly save it into the database with its region name. Do I save multiple county IDs with comma or whats the right way.

 

Please advise. The question maybe basic but I need your feedback. :)

 

Thank you!

Link to comment
https://forums.phpfreaks.com/topic/211242-how-to-group-countries-into-regions/
Share on other sites

Thanks for the reply tomtimms,

 

It is the Supplier (not the developer) who will create Regions (grouping of countries) at runtime for his products delivery to those countries and we don't know what those countries the supplier will choose from the Listbox.

 

For example, the user creates a tstShippingRegion1 and select the countries for the region under it, i.e :

 

tstShippingRegion1

Germany

France

Thailand

 

The purpose is to indicate customers that the supplier will only ship items to this region and the countries under it.

 

And for this I need to save this Region information in the database. How do you suggest I do it.

 

Kindly let me know am I on the right track for saving the information in the tables. I need help and guidance.

 

Please send in your feedback. :)

Archived

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

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.