View Single Post
  #7  
Old 01-26-2009, 12:10 PM
 
ChristineP ChristineP is offline
 

eXpert
  
Join Date: Jul 2008
Posts: 310
 

Default Re: Displaying a single custom field on product page

Awesome! I got this working for one of my extra fields by using the method you posted to call the extra field by it's name. Can you direct me to where I can find how to call out other extra fields from the same modules/Extra_Fields/product.tpl ?

This is what I used in my customer/main/product.tpl to capture the field name:
{if $active_modules.Extra_Fields ne ""}{$product.extra_fields.Manual.value}
{include file="modules/Extra_Fields/product.tpl"}
{/if}

Christine

Quote:
Originally Posted by toltion
I find it's best to call the Extra field by it's name, not it's index. The index can change as you add/delete extra fields. Here's a sample of what I use and it works fine for me. The Name of my extra field is "No Ship AIR?" -

Code:
{section name=field loop=$extra_fields} {if $extra_fields[field].field eq "No Ship AIR?"} {if $extra_fields[field].field_value ne ""}{$extra_fields[field].field_value}{/if} {/if} {/section}
__________________
______________
version 4.1.9 Gold
Reply With Quote