Jump to content

New "on_sale"-like option in product list


4140

Recommended Posts

I've added the option to display an image in a product's page when a checkbox is checked in BO. It's just like the on_sale option and to add it I've copied and modified all the lines of text about on_sale in all core files, BO and product page, also created a field in the data base.

 

All works fine until the moment I decided to add a text to the product's listing in product list if the checkbox is marked.

 

In product.tpl I'm calling the image with the following line

{if $product->free_bag}somethig-something{/if}

Just like the on_sale function is called.

 

In product-list.tpl this does not work, so I check how on_sale is being called and modify it to get the following

{if isset($product.free_bag) && $product.free_bag == 1}something-something{/if}

But nothing happens.

 

What am I missing/doing wrong here?

Link to comment
Share on other sites

It isn't there. I can't understand why - I've added it in all the core files where on_sale was mentioned and in the template files where I need it. Still works in product page and homefeatured, but not in product-list.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...