[email protected] Posted September 16, 2013 Share Posted September 16, 2013 Hi, I want to put a picture Hiperlink ( www.solusen.com) on featured products: homefeatured.tpl change? {if $product.id_product=='X'} {/if} anyone can help me? Link to comment Share on other sites More sharing options...
vekia Posted September 16, 2013 Share Posted September 16, 2013 you use default homefeatured module? Link to comment Share on other sites More sharing options...
[email protected] Posted September 16, 2013 Author Share Posted September 16, 2013 Yes, I use default homefeatured module. Link to comment Share on other sites More sharing options...
vekia Posted September 16, 2013 Share Posted September 16, 2013 so, in this module .tpl file you've got line: <a href="{$product.link}" title="{$product.name|escape:html:'UTF-8'}" class="product_image"><img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home')}" height="{$homeSize.height}" width="{$homeSize.width}" alt="{$product.name|escape:html:'UTF-8'}" /></a> if you want to use if condition you mentioned, use this code: {if $product.id_product=='X'} <a href="YOUR_LINK_HERE"> <img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home')}" height="{$homeSize.height}" width="{$homeSize.width}" alt="{$product.name|escape:html:'UTF-8'}" /> </a> {else} {* IF PRODUCT ID DIFFERENT - DISPLAY NORMAL PICTURE WITH NORMAL HYPERLINK *} <a href="{$product.link}" title="{$product.name|escape:html:'UTF-8'}" class="product_image"><img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home')}" height="{$homeSize.height}" width="{$homeSize.width}" alt="{$product.name|escape:html:'UTF-8'}" /></a> {/if} Link to comment Share on other sites More sharing options...
[email protected] Posted September 16, 2013 Author Share Posted September 16, 2013 Well! but now, does not show pictures of feature product Link to comment Share on other sites More sharing options...
vekia Posted September 16, 2013 Share Posted September 16, 2013 so you're 100% sure that you use default module with default theme? can you show your original .tpl file? what ps version? (code above is from 1.5.5) Link to comment Share on other sites More sharing options...
[email protected] Posted September 16, 2013 Author Share Posted September 16, 2013 Yes i sure 100%. PS 1.5.5 This is original code whitout change a href="{$product.link|escape:'html'}" title="{$product.name|escape:html:'UTF-8'}" class="product_image"><img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home_default')|escape:'html'}" height="{$homeSize.height}" width="{$homeSize.width}" alt="{$product.name|escape:html:'UTF-8'}" />{if isset($product.new) && $product.new == 1}<span class="new">{l s='New' mod='homefeatured'}</span>{/if}</a> <p class="s_title_block"><a href="{$product.link|escape:'html'}" title="{$product.name|truncate:50:'...'|escape:'htmlall':'UTF-8'}">{$product.name|truncate:35:'...'|escape:'htmlall':'UTF-8'}</a></p> Link to comment Share on other sites More sharing options...
vekia Posted September 16, 2013 Share Posted September 16, 2013 my fault instead of: <img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home')}" use: <img src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home_default')}" Link to comment Share on other sites More sharing options...
[email protected] Posted September 16, 2013 Author Share Posted September 16, 2013 it works!!!It´s great! I´m really happy!! Thanks a looooooooooooot Vekia!! Link to comment Share on other sites More sharing options...
vekia Posted September 16, 2013 Share Posted September 16, 2013 you're welcome glad that i could help you a little thanks for your attention about issue with image we fixed it together im going to mark this topic as [solved] best regards Link to comment Share on other sites More sharing options...
Recommended Posts