0
votes

The customer's IP address is stored against the order record in the back end of Magento (ver 1.7.0.2 but it is not available as a variable to add to the New Order Confirmation Email.

Can anyone help me change the email template so that I can get this field added to the email?

Many thanks

1
U can change default email template from /app/locale/en_US/template/email/monojit
How to add new field value in email template for this check expertwebadvisor.com/… and stackoverflow.com/questions/11393479/…monojit
Thanks for your reply but the links do not really help. I am not looking to a new custom variable. The IP address already exists against every customer order. I understand how to change the order email template but I am looking for a way of getting this field that already exists on to the template. ThanksMatt
ok..so u want pass your custom variable (ip address) in order mail.right!do u check this three links stackoverflow.com/questions/7358971/… , marius-strajeru.blogspot.in/2010/04/… and stackoverflow.com/questions/11393479/…monojit

1 Answers

1
votes

6 months late maybe, but is this what you're looking for?

$order->getRemoteIp()

I've not tried it in the context of an email template but I'd guess this:

{{var remote_ip}}

or failing that, try:

{{var order.getRemoteIp()}}

FWIW I found the getRemoteIp() function used in app/design/adminhtml/default/default/template/sales/order/view/info.phtml.