timovanham Posted May 22, 2013 Share Posted May 22, 2013 hello, is there a way to add the customer comments in the order e-mail? which macro can i use? thanks in advance. Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 22, 2013 Share Posted May 22, 2013 Welcome timovanham! Glad to see you made it to the forums. Try {$DATA.customer_comments} If that doesn't work, let us know what the subject line of the email says and we can provide a better answer. Quote Link to comment Share on other sites More sharing options...
rockyrobin Posted May 22, 2013 Share Posted May 22, 2013 Hi bsmither By chance, I was looking at trying to add the same functionality this morning and saw this post. I have tried adding the {$DATA.customer_comments} to the order recieved template and then tested but it didnt appear to pull through the Customer Comments. Any advice? (timovanham, apologies for jumping onto your post) Regards Robin Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 22, 2013 Share Posted May 22, 2013 What is the exact subject line of your "Order Received" email? Quote Link to comment Share on other sites More sharing options...
timovanham Posted May 22, 2013 Author Share Posted May 22, 2013 hi bsmither, i added {$DATA.customer_comments} in the order received template and it works! now i see that only the first ordered product is listed in the same email (more products are ordered) this is what's in that template: {foreach from=$PRODUCTS item=product} {/foreach} {foreach from=$TAXES item=tax} {/foreach} Item Quantity Costs {$product.name} {$product.product_options} {$product.quantity} {$product.price} how can i change it so every product is shown in the e-mail? thanks Quote Link to comment Share on other sites More sharing options...
rockyrobin Posted May 22, 2013 Share Posted May 22, 2013 Hi Smither Subject Line of the Order is:- New Order #130521-163207-5859 Essentially some customers like to add their own PO numbers/Comments and we would like to include these on the order confirmations to Admin and to the Customer. (I added the macro at the very bottom of the template if thats any help as well) Quote Link to comment Share on other sites More sharing options...
bsmither Posted May 22, 2013 Share Posted May 22, 2013 If the new variable is not showing, be sure to clear CubeCart's cache (Admin, Maintenance, Rebuild tab, Clear Cache). When editing the HTML portion of the email, it is best to have the editor in source mode. Unfortunately, certain Smarty commands must be enclosed in HTML comment tags, and that poses problems when viewing WYSIWYG mode. This is the relevant part that you must restore: <!--{foreach from=$PRODUCTS item=product}--> <tr> <td> {$product.name}<br /> {$product.product_options}</td> <td> {$product.quantity}</td> <td> {$product.price}</td> </tr> <!--{/foreach}--> <tr> <td> </td> <td> Shipping: {if $DATA.ship_method}({$DATA.ship_method}){/if}</td> <td> {$DATA.shipping}</td> </tr> <tr> <td> </td> <td> Discount:</td> <td> {$DATA.discount}</td> </tr> <tr> <td> </td> <td> Subtotal:</td> <td> {$DATA.subtotal}</td> </tr> <!--{foreach from=$TAXES item=tax}--> <tr> <td> </td> <td> {$tax.tax_name}: ({$tax.tax_percent}%)</td> <td> {$tax.tax_amount}</td> </tr> <!--{/foreach}--> Quote Link to comment Share on other sites More sharing options...
timovanham Posted May 22, 2013 Author Share Posted May 22, 2013 hi bsmither, change the layout to code and changed the parts, it works now. thank you very much!! 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.