Guest Posted March 2, 2014 Share Posted March 2, 2014 (edited) Hey guys, Hope you are all doing well. {if $product.id_product != 118} Text1 {else} Text2 {/if} Could anyone shine some light onto what I am I doing wrong with this statement? Thanks in advance, eggo Edited March 2, 2014 by Guest (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted March 2, 2014 Share Posted March 2, 2014 in product tpl $product variable is an object, not an array, so you have to use $product->id_product instead of $product.id_product. object: $product->id_product array: $product.id_product 1 Link to comment Share on other sites More sharing options...
Guest Posted March 2, 2014 Share Posted March 2, 2014 Hey vekia, I have made those changes but if I add that to product.tpl it still gives me blank page. Any ideas? {if $product->id_product != 118} <p> text1 </p> {else} <p> text2 </p> {/if} Link to comment Share on other sites More sharing options...
vekia Posted March 2, 2014 Share Posted March 2, 2014 oops my bad, $product->id not $product->id_product 1 Link to comment Share on other sites More sharing options...
Guest Posted March 2, 2014 Share Posted March 2, 2014 Hey vekia, That worked perfect. Your the man! Appreciate it. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now