KSD Posted May 25, 2015 Share Posted May 25, 2015 Hello, I would like to know where I can get more info about the macro language (commands and syntax), CC is using within email templates.I have tried some sample code like: {if {$DATA.gateway}==Print_Order_Form}{True!}{/if}.But it didn't work. Quote Link to comment Share on other sites More sharing options...
KSD Posted May 25, 2015 Author Share Posted May 25, 2015 Maybe {if {$DATA.gateway}==Print_Order_Form}{echo True!}{/if}. Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 25, 2015 Share Posted May 25, 2015 The template language is "Smarty".{if $DATA.gateway eq 'Print_Order_Form'}Return form with payment.{/if} Quote Link to comment Share on other sites More sharing options...
KSD Posted May 26, 2015 Author Share Posted May 26, 2015 (edited) I have tried this little example, but it didn't work. I added this code in --------<p> <span style="font-size: 14px;">Dann überweisen Sie bitte den Gesamtbetrag an die gegebene Bankverbindung. </span></p><p> </p><p> {if $DATA.gateway eq 'Print_Order_Form'}Return form with payment.{/if}</p><p> <span style="font-size: 14px;">Bitte bewahren Sie diese E-Mail für Ihre Unterlagen auf. Es ist möglich, den Status Ihrer Bestellung online einzusehen.</span></p><p> Edited May 26, 2015 by KSD Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 26, 2015 Share Posted May 26, 2015 Let us know which email template. Then we can make sure we have the correct spelling and have the correct array for which it can be found.You might also try this -- add {debug} to the end of the email's contents. Even though the content will be sent out in an email, the Smarty debug data may be shown in a popup window, or it may be included in the email -- I forget which.The debug data will show what we need to know. Quote Link to comment Share on other sites More sharing options...
KSD Posted May 27, 2015 Author Share Posted May 27, 2015 I used the 'order complete' email template.Then I set one order to'completed' and I expected that an email is sent out.Debug switch was set.Same result. No email sent out. <p> <span style="font-size: 14px;">Hallo {$DATA.first_name} {$DATA.last_name},</span></p><p> </p><p> <span style="font-size: 14px;">wir haben am {$DATA.ship_date} Ihre Bestellung Nummer {$DATA.cart_order_id} vom {$DATA.order_date} an {$DATA.first_name} {$DATA.last_name}nach {$DATA.SHIPPING.town} versandt.</span></p><p> <span style="font-size: 14px;">Im Express-Versand erwarten Sie die Lieferung in etwa 1-2 Arbeitstagen.</span></p><p> {if $DATA.gateway eq 'Pay On Delivery'}</p><p> Ihre Sendung wurde als Nachnahme-Sendung verschickt.</p><p> Bitte legen Sie den Gesamtbetrag der Bestellung über {$DATA.total} Euro schon einmal in bar für den Postboten zur Seite.</p><p> {/if}</p><p> <span style="font-size: 14px;">Die Nachverfolgungsnummer zu Ihrer Sendung lautet: {$DATA.ship_tracking}.</span></p><p> <span style="font-size: 14px;">Sie können Ihre Sendung <a href="https://www.deutschepost.de/sendung/simpleQuery.html">hier nachverfolgen</a>,</span></p><p> <span style="font-size: 14px;">Dort wird Ihnen auch der voraussichtliche Zustellungszeitpunkt genannt.</span></p><p> <span style="font-size: 14px;">Erfahrungsgemäß dauert es bis zu 24 Stunden nach Versand, bevor Sie erste Informationen in der Nachverfolgung erhalten.</span></p><p> </p><p> <span style="font-size: 14px;">Sie haben Fragen?</span></p><p> <span style="font-size: 14px;">Wollen mal klönen oder ratschen?</span></p><p> <span style="font-size: 14px;">Rufen Sie an!</span></p><p> <span style="font-size: 14px;">Oder schreiben Sie uns!</span></p><p> </p><p> <span style="font-size: 14px;">Und nach Erhalt der Ware - lesen wir gern, ob Sie zufrieden waren oder ob Sie Dinge bemängeln! </span></p><p> </p><p> {debug}</p> Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 27, 2015 Share Posted May 27, 2015 This is not the correct variable: {$DATA.SHIPPING.town}Although this would not cause a fault, the correct variable is: {$SHIPPING.town}As well as using the $DATA array to use elements that are in other arrays: {$SHIPPING.first_name}, {$SHIPPING.last_name} Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.