SOLVED Formatting of billing and shipping address?

  • Posts: 42
  • Thank you received: 2
12 years 11 months ago #39164

Hello again!
Is it possible to change the formatting of the billing and shipping addresses? They currently are not in a "standard" format for USA. As is, they look like:

Mr Test User
123 First
49685 Traverse City Michigan
United States of America
Telephone: 2312312311


But I would like them to appear like this:

Mr Test User
123 First
Traverse City, Michigan
49685
United States of America
Telephone: 2312312311


Subtle difference, but that is how we are used to seeing it. Is this possible in the Business edition using overrides (I currently have Essential, but am considering upgrading to Business), or would this require modification of code?

Thank You,
Matt Heffron
Traverse City, MI


It's amazing how the omission of a semicolon can absolutely ruin an otherwise pleasant evening.
Last edit: 12 years 11 months ago by spoonbow. Reason: Figured it out

Please Log in or Create an account to join the conversation.

  • Posts: 218
  • Thank you received: 6
12 years 11 months ago #39173

I am wondering the same thing.

In Australia we write our addresses:

15 Peter Street
Bondi , New South Wales 2026
Australia

(Street Address)
(Suburb/Town),(State), (Post code)
(Country)

Please Log in or Create an account to join the conversation.

  • Posts: 42
  • Thank you received: 2
12 years 11 months ago #39176

Here's how I resolved this on my setup.

In Hikashop configuration go to Display->Views. Select your template and "Front End" in the drop down lists at the top of the page. If it's not right on top of the list, filter on "address_template", then click on it to edit. Cut and Paste the fields into the desired order/display. For you it would be:

{address_company}
{address_title} {address_firstname} {address_lastname}
{address_street}
{address_city}, {address_state} {address_post_code}
{address_country}

Notice the added comma after {address_city}. Editing and saving this template resulted in the address being formatted properly in the emails sent out to the customer.

If you select "Back End" from the drop down list you will find another "address_template" that appears to be identical to the one for the front end. I had assumed that editing this template would result in the correct address format being applied when generating an invoice from an order in the back end, but this doesn't seem to be the case. Will keep hunting for a resolution on that one.

Cheers
Matt


It's amazing how the omission of a semicolon can absolutely ruin an otherwise pleasant evening.
The following user(s) said Thank You: woonydanny

Please Log in or Create an account to join the conversation.

  • Posts: 83103
  • Thank you received: 13415
  • MODERATOR
12 years 11 months ago #39267

Hi,

The address_template view file for the back end is indeed what you should change. Be careful to choose the correct template when editing it. If you edit it for another template than the one you're using, you won't see the change.

The following user(s) said Thank You: spoonbow

Please Log in or Create an account to join the conversation.

  • Posts: 10
  • Thank you received: 0
12 years 11 months ago #39276

Nicholas, this doesn't seem to be affecting the "New" button link to the popup form. Which area do I modify again?

Please Log in or Create an account to join the conversation.

  • Posts: 42
  • Thank you received: 2
12 years 11 months ago #39279

Nicolas
That was indeed the problem - I was editing the wrong template. Works perfectly now that I've done it the right way... :blush:

Thanks!
Matt


It's amazing how the omission of a semicolon can absolutely ruin an otherwise pleasant evening.
Last edit: 12 years 11 months ago by spoonbow. Reason: Spelling error

Please Log in or Create an account to join the conversation.

  • Posts: 83103
  • Thank you received: 13415
  • MODERATOR
12 years 11 months ago #39387

For the address form itself, you need to configure your custom address fields via the menu Display->Custom fields.

Please Log in or Create an account to join the conversation.

Time to create page: 0.088 seconds
Powered by Kunena Forum