View Single Post
  #1  
Old 08-03-2015, 12:05 PM
paintthetown's Avatar
paintthetown paintthetown is offline
 
Join Date: Jul 2015
Posts: 1
Default Displaying visible and hidden attributes in confirmation email

I have tried all of the ideas in other threads for getting attributes (visible and hidden) for a specific product (or all products ordered) in the confirmation email, but so far nothing is working. At best I get some Russian characters.

Below is a screen shot of the attributes set up:


Below is an excerpt of the code which I've set up to test different options:

Code:
<!-- Order item: start -->
<#list order.items as orderItem>
<tr>

  	<td align="left" valign="top" style="text-align: left;font-family: Arial,sans-serif;font-size: 14px;line-height: 

150%;color: #FFFFFF;padding-top:2px;padding-left:10px">

      	<!-- Order item: start -->
      	${orderItem.name} <br>
    Test 1
	${orderItem.visibleattributes[0].name} ${orderItem.visibleattributes[0].value}
	${orderItem.visibleattributes[1].name} ${orderItem.visibleattributes[1].value}
	${orderItem.visibleattributes[2].name} ${orderItem.visibleattributes[2].value}
	${orderItem.visibleattributes[3].name} ${orderItem.visibleattributes[3].value}
      
    Test 2
    ${orderItem.attributes[0].name} ${orderItem.attributes[0].value}
    ${orderItem.attributes[1].name} ${orderItem.attributes[1].value}
    ${orderItem.attributes[2].name} ${orderItem.attributes[2].value}
    ${orderItem.attributes[3].name} ${orderItem.attributes[3].value}

    Test 3
    ${order.items[0].attributes[0].name} at ${order.items[0].attributes[0].value}
    ${order.items[0].attributes[1].name} at ${order.items[0].attributes[1].value}
    ${order.items[0].attributes[2].name} at ${order.items[0].attributes[2].value}
    ${order.items[0].attributes[3].name} at ${order.items[0].attributes[3].value}
      ${order.items[0].attributes[4].name} at ${order.items[0].attributes[4].value}
    ${order.items[1].attributes[4].name} at ${order.items[1].attributes[4].value}
    
    Test 4
    ${orderItem.attributes.name} ${orderItem.attributes.value}
    
    Test 7
    <#list orderItem.visibleAttributes as visibleAttribute>
	    ${visibleAttribute.name}: ${visibleAttribute.value}
	</#list>
    
    Test 8
    <#list orderItem.attributes as attribute>
	    ${attribute.name}: ${attribute.value}
	</#list>
    
    </td>
</tr>
</#list>
<tr><td align="left" valign="top" style="text-align: left;font-family: Arial,sans-serif;font-size: 14px;line-height: 

150%;color: #FFFFFF;padding-top:2px;padding-left:10px">    Test 5
    ${order.items[0].attributes[1].name} at ${order.items[0].attributes[1].value}</td></tr>
  
<!-- Order items : end -->
<!-- Order item: end -->
<#list orderItem.visibleAttributes as visibleAttribute>
 <tr>
  <td style="font-family: Arial,Helvetica,sans-serif;font-size: 14px;line-height: 20px; color: #FFFFFF; padding-top: 5px;">
    tEST 6
    ${visibleAttribute.name}: ${visibleAttribute.value}
  </td>
 </tr>
</#list>
What am I doing wrong?

Sorry here's the pic of the attributes set up:

Last edited by Wendy; 08-05-2015 at 09:22 AM.