Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

I want to dsiplay two letter states on the order.tpl

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 05-22-2006, 05:33 PM
 
rcg rcg is offline
 

Member
  
Join Date: Mar 2005
Posts: 18
 

Default I want to dsiplay two letter states on the order.tpl

As the subject states...

Right now when reviewing orders I see something like

Bob Smith
123 Any Street
San Francisco California 94105

I want to see

Bob Smith
123 Any Street
San Francisco CA 94105

I know the the codes are in there... How do I mod {$customer.s_statename}???
__________________
X-Cart GOLD 4.0.17
Affiliate
RMA
AOM
Configurator
---
PHP 4.4.2
MYSQL 4.1.21
Reply With Quote
  #2  
Old 05-23-2006, 06:09 AM
 
geckoday geckoday is offline
 

X-Wizard
  
Join Date: Aug 2005
Posts: 1,073
 

Default

I believe you use $customer.s_state instead of $customer.s_statename
__________________
Manuka Bay Company
X-Cart Version 4.0.19 [Linux]

UGG Boots and other fine sheepskin products
http://www.snowriver.com
Reply With Quote
  #3  
Old 05-24-2006, 10:24 AM
 
rcg rcg is offline
 

Member
  
Join Date: Mar 2005
Posts: 18
 

Default

Thank you that worked.

I thought initially it was stateid or something.
__________________
X-Cart GOLD 4.0.17
Affiliate
RMA
AOM
Configurator
---
PHP 4.4.2
MYSQL 4.1.21
Reply With Quote
  #4  
Old 07-27-2006, 06:48 PM
 
carpeperdiem carpeperdiem is offline
 

X-Guru
  
Join Date: Jul 2006
Location: New York City, USA
Posts: 5,399
 

Default

Thank you for this code.

While we're on this page, can someone suggest the best way to if/else remove the country --

{if $userinfo.default_fields.b_country} = United States, then display nothing at all... else, display the country.

Since we're shipping from the US to primarily US addresses, US Postal does not like the extra line under the "City, ST ZIP" -- I'd very much like to remove the country, only for "United States" -- I'm still learning smarty editing, and I'm sure it's a 2 liner...

Anyone know how to do this?

Thanks!

Jeremy
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 06:00 AM.

   

 
X-Cart forums © 2001-2020