dpodseo Posted May 7, 2012 Share Posted May 7, 2012 Bonjour a tous, J'ai encore un petit souci. Avec le module "produits phare en page d'accueil". Je souhaite mettre 10 produits en 2 ligne de 5. quand je met 9 produits ok, tout est bien j'ai une ligne de 5 puis une ligne de 4. Quand je passe a 10 produits, ma ligne du bas remonte et chevauche la ligne du haut quelqu'un aurait une idée ? Merci d'avance, Link to comment Share on other sites More sharing options...
capsizone Posted May 9, 2012 Share Posted May 9, 2012 Bonjour, Avez-vous modifié le fichier homefeatured.tpl ? Ouvrez ce fichier (/modules/homrfeatured/homefeatured.tpl) et à la ligne 33 mettez une valeur de 5 (n'oubliez pas de forcer la compilation et de désactiver le cache (Préférences >> Performances)). Quelques modifs dans le CSS et c'est bon. Link to comment Share on other sites More sharing options...
coeos.pro Posted May 9, 2012 Share Posted May 9, 2012 si il a acheté un thème la ligne 33 ne doit pas correspondre à la ligne 33 que tu as en tête (module de base) ou alors il a acheté le thème chez toi. Tu as un lien vers ta boutique dpodseo ? Link to comment Share on other sites More sharing options...
capsizone Posted May 9, 2012 Share Posted May 9, 2012 @coeos.pro C'est pas faux mais même avec un "homefeatured" modifié ça doit pas être très loin ! @dpodseo Modifiez la valeur aux environs de la ligne 33... Link to comment Share on other sites More sharing options...
coeos.pro Posted May 9, 2012 Share Posted May 9, 2012 en début de fichier il y a 25 lignes : {* * 2007-2011 PrestaShop * * NOTICE OF LICENSE * * This source file is subject to the Academic Free License (AFL 3.0) * that is bundled with this package in the file LICENSE.txt. * It is also available through the world-wide-web at this URL: * http://opensource.org/licenses/afl-3.0.php * If you did not receive a copy of the license and are unable to * obtain it through the world-wide-web, please send an email * to [email protected] so we can send you a copy immediately. * * DISCLAIMER * * Do not edit or add to this file if you wish to upgrade PrestaShop to newer * versions in the future. If you wish to customize PrestaShop for your * needs please refer to http://www.prestashop.com for more information. * * @author PrestaShop SA <[email protected]> * @copyright 2007-2011 PrestaShop SA * @version Release: $Revision: 6594 $ * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) * International Registered Trademark & Property of PrestaShop SA *} donc ça risque d'être la ligne 33 à +/- 25 lignes, c'est plus simple et rapide de copier la ligne ici, sans compter que la la modif que tu donnes ne concerne que le smarty et pas le css correspondant, à mon avis c'est le css qu'il faut modifier et non le smartty. Link to comment Share on other sites More sharing options...
dpodseo Posted May 20, 2012 Author Share Posted May 20, 2012 (edited) Bonjour a tous merci pour vos réponses. Dsl pour le temps de ma réponse lo gt en vacances. En fait j'ai bien modifié le fichier homefeatured.tpl et ca roule, j'ai effectivement du faire des modifs en css. Le template de base c'est clean and simple pour v1.4 Donc en fait quand j'ai 9 produits en home c'est ok 5 produits sur la premiere ligne et 4 sur la deuxieme mais a 10 tout par en sucette, je ne peut donc pas faire de modif css car ce sont les meme valeurs qu'il y ait 10 produits ou 9. Tout va bien tant que je ne modifie pas la configuration du module a 10 dans le Bo Je suis vraiment en galère sur ce coup et vous remercie par avance. Mon home featured.tpl <!-- MODULE Home Featured Products --> <div id="featured-products_block_center" class="block products_block"> <h2>{l s='Featured products' mod='homefeatured'}</h2> {if isset($products) AND $products} <div class="block_content"> {assign var='liHeight' value=322} {assign var='nbItemsPerLine' value=5} {assign var='nbLi' value=$products|@count} {math equation="nbLi/nbItemsPerLine" nbLi=$nbLi nbItemsPerLine=$nbItemsPerLine assign=nbLines} {math equation="nbLines*liHeight" nbLines=$nbLines|ceil liHeight=$liHeight assign=ulHeight} <ul style="height:{$ulHeight}px;"> {foreach from=$products item=product name=homeFeaturedProducts} <li class="ajax_block_product {if $smarty.foreach.homeFeaturedProducts.first}first_item{elseif $smarty.foreach.homeFeaturedProducts.last}last_item{else}item{/if} {if $smarty.foreach.homeFeaturedProducts.iteration%$nbItemsPerLine == 0}last_item_of_line{elseif $smarty.foreach.homeFeaturedProducts.iteration%$nbItemsPerLine == 1}clear{/if} {if $smarty.foreach.homeFeaturedProducts.iteration > ($smarty.foreach.homeFeaturedProducts.total - ($smarty.foreach.homeFeaturedProducts.total % $nbItemsPerLine))}last_line{/if}"> <h5><a href="{$product.link}" title="{$product.name|truncate:32:'...'|escape:'htmlall':'UTF-8'}">{$product.name|truncate:48:'...'|escape:'htmlall':'UTF-8'}</a></h5> <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> <div> <a class="button" href="{$product.link}" title="{l s='View' mod='homefeatured'}">{l s='View' mod='homefeatured'}</a> {if $product.show_price AND !isset($restricted_country_mode) AND !$PS_CATALOG_MODE}<p class="price_container"><span class="price">{if !$priceDisplay}{convertPrice price=$product.price}{else}{convertPrice price=$product.price_tax_exc}{/if}</span></p>{else}<div style="height:21px;"></div>{/if} <!--{if ($product.id_product_attribute == 0 OR (isset($add_prod_display) AND ($add_prod_display == 1))) AND $product.available_for_order AND !isset($restricted_country_mode) AND $product.minimal_quantity == 1 AND $product.customizable != 2 AND !$PS_CATALOG_MODE} {if ($product.quantity > 0 OR $product.allow_oosp)} <a class="exclusive ajax_add_to_cart_button" rel="ajax_id_product_{$product.id_product}" href="{$link->getPageLink('cart.php')}?qty=1&id_product={$product.id_product}&token={$static_token}&add" title="{l s='Add to cart' mod='homefeatured'}">{l s='Add to cart' mod='homefeatured'}</a> {else} <span class="exclusive">{l s='Add to cart' mod='homefeatured'}</span> {/if} {else} <div style="height:23px;"></div> {/if}--> </div> </li> {/foreach} </ul> </div> {else} <p>{l s='No featured products' mod='homefeatured'}</p> {/if} </div> <!-- /MODULE Home Featured Products --> Edited May 20, 2012 by dpodseo (see edit history) Link to comment Share on other sites More sharing options...
Atch Posted May 21, 2012 Share Posted May 21, 2012 un lien pour visualiser ce qu'il se passe ferait gagner du temps à tout le monde... V++ Atch Link to comment Share on other sites More sharing options...
Virtu Posted October 10, 2012 Share Posted October 10, 2012 bonjour pour ma 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