Jump to content

Edit History

Shiraz

Shiraz

Hi,

Can anyone show me the simplest way to capitalize a passed variable in the confirmation email?

I'm required to do this to add a payment method to my site. The name of the payment method is currently not being capitalized in the confirmation email, and I have been required to capitalize it.

I've found the relevant mail template in mails/en/order_conf.html, however the word I need to capitalize is encoded in a variable ('{payment}'). I have no idea how to alter the contents of the variable. 

Can anyone suggest an easy fix for this?

Regards,

 

Shiraz

Shiraz

Hi,

Can anyone show me the simplest way to capitalize a passed variable in the confirmation email?

I'm required to do this to add a payment method to my site. The name of the payment method is currently not being capitalized in the confirmation email, and I have been required to capitalize it.

I've found the mail templates in mails/en/order_conf.html, however the word I need to capitalize is encoded in a variable ('{payment}'). I have no idea how to alter the contents of the variable. 

Can anyone suggest an easy fix for this?

Regards,

 

Shiraz

Shiraz

Hi,

Can anyone show me the simplest way to capitalize a passed variable in the confirmation email?

I'm required to do this to add the payment method to my site. The name of the payment method is currently not being capitalized in the confirmation email, and I have been required to capitalize it.

I can see the relevant part of the email being generated in templates/checkout/order-confirmation.tpl on this line:

  Quote

<li>{l s='Payment method: %method%' d='Shop.Theme.Checkout' sprintf=['%method%' => $order.details.payment]}</li>

Expand  

My knowledge of this stuff is not good enough for me to trace it back any further. Ideally I'd like to simply add code which says if the first letter is not a capital, change it to a capital. Alternatively, can anyone suggest an easy fix for this.

Regards,

 

×
×
  • Create New...