Now what I am trying to figure out is how to access those resx files inside of the e-mail templates using nvelocity. When a user checks out I store their two character language as a order note and then call that in the e-mail to get their language.
Code: Select all
#foreach ($note in $order.notes)
#if ($note.Comment.Contains("Language"))
#set ($locale = $note.Comment.Replace("Language,",""))
#end
#end
#if ($locale == "fr")
oui
#elseif ($locale == "en")
Yes
#end
** EDIT**
Ok. I found some code that works that I tested on the admin sendmail page but I need to know how to get it to work with e-mails not sent manually.
What I did was create a class that takes 2 inputs (entry and culture). If I have CameraDescription in my resx file I call $lang.GetItem("CameraDescription",$locale) from my e-mail template and add a parameter in the SendEmail.ascx.cs file that uses the resource helper class as the object.
Any Ideas on how to get this to work on automated e-mails? I can get access to the source code if needed, but I would rather not touch it.