VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: flidais on March 27, 2012, 10:28:35 AM

Title: Featured product styling in category view
Post by: flidais on March 27, 2012, 10:28:35 AM
Hello

I was looking for the solution, but couldnt find it anywhere.
My problem is that i want to style featured products in category view, so the clients can see which products, are featured.

How exactly can i get the information that the products type is featured?
I did var_dump of $this-> products in category view template, but there is no such info about type of products, is there any way to check it in category view?

Im using VirtueMart 2.0.2
Title: Re: Featured product styling in category view
Post by: danio_d on April 30, 2012, 23:37:12 PM
Hi,

in category template:
          <?php if ($product->product_special == 1) { ?>
                  <div>PROMOTION!!! </div>
               <?php    }?>


and in details:
                              <?php if ($this->product->product_special == 1) { ?>
                  <div class="promocja"> </div>
               <?php    }?>