- Posts: 35
- Thank you received: 1
3 Letter Code instead of State_Name on Invoices
11 years 6 months ago #195860
by shifty_
3 Letter Code instead of State_Name on Invoices was created by shifty_
-- HikaShop version -- : 2.3.5
-- Joomla version -- : 3.3.6
-- PHP version -- : 5.5.1
-- Browser(s) name and version -- : All Browsers
Hi There
I have been customising the Shipping and Tax Invoices for the ISIS template by modifying the invoice.php override file.
I have made some changes to the ISIS Address Template too (address_template.php). But I can't figure out how to use the 3 Letter State Code instead of the State Name in the address template.
For example I now have the shipping and billing address showing as:
Sydney New South Wales 2000.
But I would like it to be:
Sydney NSW 2000
Is this possible? If so how would I go about this?
Kind regards
Mark
-- Joomla version -- : 3.3.6
-- PHP version -- : 5.5.1
-- Browser(s) name and version -- : All Browsers
Hi There
I have been customising the Shipping and Tax Invoices for the ISIS template by modifying the invoice.php override file.
I have made some changes to the ISIS Address Template too (address_template.php). But I can't figure out how to use the 3 Letter State Code instead of the State Name in the address template.
For example I now have the shipping and billing address showing as:
Sydney New South Wales 2000.
But I would like it to be:
Sydney NSW 2000
Is this possible? If so how would I go about this?
Kind regards
Mark
Please Log in or Create an account to join the conversation.
11 years 6 months ago #195866
by Xavier
Replied by Xavier on topic 3 Letter Code instead of State_Name on Invoices
Hi,
This will require some code to edit the display.
For example in the view "address / show" you will have to replace:
By a code which will edit the address state name by its state code.
It require php knowledges.
This will require some code to edit the display.
For example in the view "address / show" you will have to replace:
Code:
echo $this->addressClass->displayAddress($this->fields,$this->address,'address');
Code:
// Get the address html
$address = $this->addressClass->displayAddress($this->fields,$this->address,'address');
// Then add code to process it in order to replace the state name by the state code
It require php knowledges.
Please Log in or Create an account to join the conversation.
Time to create page: 0.158 seconds