gabiatti Posted June 5, 2014 Share Posted June 5, 2014 (edited) I'm using the following code in my product.tpl to have an image of the manufacturer and a link to open manufacturer's products page. <div class="product_manufacturer"> <a href="manufacturer.php?id_manufacturer={$product_manufacturer->id_manufacturer}" title="{l s='See all products...'}"><img src="http://mysite.com/img/m/{$product_manufacturer->id_manufacturer}-medium_default.jpg" align="right" /></a> </div> It was working well until I able my friendly URLs. Now, when I click in these links I receive a 404-page, because the url keep this address mysite.com/br/electrical/manufacturers?id_manufacturer=43 where's BR is the language and ELECTRICAL is the category and I need to call the url as follow: mysite.com/manufacturers?id_manufacturer=43 without the language and Category Anyone has a solution for that? Edited June 5, 2014 by gabiatti (see edit history) Link to comment Share on other sites More sharing options...
Whispar1 Posted June 5, 2014 Share Posted June 5, 2014 I'm using the following code in my product.tpl to have an image of the manufacturer and a link to open manufacturer's products page. <div class="product_manufacturer"> <a href="manufacturer.php?id_manufacturer={$product_manufacturer->id_manufacturer}" title="{l s='See all products...'}"><img src="http://mysite.com/img/m/{$product_manufacturer->id_manufacturer}-medium_default.jpg" align="right" /></a> </div> Here is how I wrote mine on my product pages (I also use an image instead of text) <a href="{$link->getmanufacturerLink($product->id_manufacturer, $manufacturer.link_rewrite)|escape:'htmlall':'UTF-8'}">{if $product_manufacturer->id_manufacturer}<img src="{$base_dir}img/m/{$product_manufacturer->id_manufacturer}.jpg" class="manu_prod_img" />{/if}</a> 1 Link to comment Share on other sites More sharing options...
gabiatti Posted June 5, 2014 Author Share Posted June 5, 2014 (edited) Perfect, I just have to change the image size to -medium_default.jpg as my default image was too big and use absolute instead of relative. <a href="{$link->getmanufacturerLink($product->id_manufacturer, $manufacturer.link_rewrite)|escape:'htmlall':'UTF-8'}">{if $product_manufacturer->id_manufacturer}<img src="img/m/{$product_manufacturer->id_manufacturer}-medium_default.jpg" align="right" class="manu_prod_img" />{/if}</a> Edited June 5, 2014 by gabiatti (see edit history) 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