VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: chadlly2003 on December 14, 2013, 03:32:32 AM

Title: Multiple Custom Fields (category view)
Post by: chadlly2003 on December 14, 2013, 03:32:32 AM
I have custom fields in the category view using this code (see below).....   My problem is that I have multiple custom fields for each product.  I only want to show one custom field on the category view rather them displaying them all for the given product.  Can someone assist me or lead me in the right direction on solving this issue

               <?php
                     foreach($product->customfields as $custom){
                     echo "<b>";
                     echo $custom->custom_title;
                     echo "</b>: ";
                     echo $custom->custom_value;
                     echo "<br>";
                     }
                     ?>

Title: Re: Multiple Custom Fields (category view)
Post by: balai on December 14, 2013, 09:54:47 AM
What you mean "show one custom field on the category " ?
Where ? how?