2

I want to add cities name on the checkout page so the customer can select their city, i tried searching online but no help till now.

3
  • Can you explain the question? If you want city to be related to multiple countries or will there be just one country where your store will operate? Mar 7 '14 at 10:17
  • i want cities for just one country.
    – user5599
    Mar 8 '14 at 10:37
  • This is not a complete answer but you could look into the blog post. blog.magepsycho.com/… Jul 24 '14 at 8:35
0

For that you have to create a customer attribute dropdown & display the same on checkout page. & on saveAction of billing address you need to save the same value. so that you can check in admin section which city customer has selected.

1
  • i also tried making attribute but its for the product and also not visible. can i apply attribute on the checkout page?
    – user5599
    Mar 9 '14 at 7:13
0

For only one country, what you can simply do is change the "text" input to "dropdown" input in billing.phtml with values as 'text', so that internally it would work like before but the user will be given a dropdown input. You can just add those options of city statically.

3
  • i tried but not working, can you please explain in detail, i have added select tag on app/design/frontend/base/default/template/checkout/onepage/billing.phtml where input title is city but its not working.
    – user5599
    Mar 9 '14 at 7:06
  • Basic concept is changing the input from text to select, and probably you are using a different theme, that should work IMHO. Mar 10 '14 at 4:44
  • but i have only one default theme
    – user5599
    Mar 10 '14 at 6:41

Not the answer you're looking for? Browse other questions tagged or ask your own question.