Baalow59 Posted April 22, 2016 Share Posted April 22, 2016 Bonjour, Nos description catégories atteigne les 800 mots, je souhaite descendre les descriptions des catégories en dessous des produits pour que le visiteur tombe directement sur les produit. Pouvez m'aider m'aider pour le procéder ? Bien à vous. Link to comment Share on other sites More sharing options...
smuch Posted April 22, 2016 Share Posted April 22, 2016 Qu'entendez-vous par "en dessous des produits" Link to comment Share on other sites More sharing options...
Baalow59 Posted April 22, 2016 Author Share Posted April 22, 2016 (edited) Je souhaite que quand le client rentre dans une catégorie produit, il arrive directement sur les produits ensuite quand il déroule vers le bas il trouve la description de la catégorie. Ci-dessous exemple : merci. Edited April 22, 2016 by Baalow59 (see edit history) Link to comment Share on other sites More sharing options...
smuch Posted April 22, 2016 Share Posted April 22, 2016 Ah oui, je vois. Malheureusement, je ne suis pas assez à l'aise avec prestashop, désolé de ne pas pouvoir vous aider. Peut-être que quelqu'un aura une idée :/ Bon courage Link to comment Share on other sites More sharing options...
DeyDDy Posted April 22, 2016 Share Posted April 22, 2016 (edited) Bonjour Baalow59, ça va se jouer dans le fichier product-list.tpl du thème mais difficile d'en dire plus sans connaitre la version prestashop utilisée Edited April 22, 2016 by DeyDDy (see edit history) Link to comment Share on other sites More sharing options...
Baalow59 Posted April 22, 2016 Author Share Posted April 22, 2016 Hello, Version 1.6.0.14 Link to comment Share on other sites More sharing options...
DeyDDy Posted April 22, 2016 Share Posted April 22, 2016 Ouvrez le fichier category.tpl de votre thème Déplacez les lignes suivantes {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <div class="content_scene"> <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {if $category->description} <div class="cat_desc rte"> {if Tools::strlen($category->description) > 350} <div id="category_description_short">{$description_short}</div> <div id="category_description_full" class="unvisible">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category.link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div>{$category->description}</div> {/if} </div> {/if} </div> {else} <span class="page-heading{if (isset($subcategories) && !$products) || (isset($subcategories) && $products) || !isset($subcategories) && $products} product-listing{/if}"><span class="cat-name">{$category->name|escape:'html':'UTF-8'}{if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'}{/if}</span>{include file="$tpl_dir./category-count.tpl"}</span> {if isset($subcategories)} {if $category->description} <div class="cat_desc"> <span class="category-name"> {strip} {$category->name|escape:'html':'UTF-8'} {if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'} {/if} {/strip} </span> {if Tools::strlen($category->description) > 450} <div id="category_description_short" class="rte">{$description_short}</div> <div id="category_description_full" class="unvisible rte">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category->link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div class="rte">{$category->description}</div> {/if} </div> {/if} </div> {/if} {/if} <!-- Category image --> <div class="content_scene_cat_bg" {if $category->id_image}style="background:url({$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html':'UTF-8'}) 0 top no-repeat; background-size:contain; min-height:{$categorySize.height}px;" {/if}></div> au dessus de ces lignes {elseif $category->id} <p class="alert alert-warning">{l s='This category is currently unavailable.'}</p> {/if} {/if} ce qui donne {include file="$tpl_dir./errors.tpl"} {if isset($category)} {if $category->id AND $category->active} <!-- Subcategories --> <div id="subcategories"> <p class="subcategory-heading"> <span> {l s='Subcategories'} </span> </p> <ul class="clearfix"> {foreach from=$subcategories item=subcategory} <li> <div class="subcategory-image"> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}" title="{$subcategory.name|escape:'html':'UTF-8'}" class="img"> {if $subcategory.id_image} <img class="replace-2x" src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'medium_default')|escape:'html':'UTF-8'}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {else} <img class="replace-2x" src="{$img_cat_dir}default-medium_default.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {/if} </a> </div> <h5><a class="subcategory-name" href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}">{$subcategory.name|truncate:25:'...'|escape:'html':'UTF-8'|truncate:350}</a></h5> {if $subcategory.description} <div class="cat_desc">{$subcategory.description}</div> {/if} </li> {/foreach} </ul> </div> {/if} {if $products} <div class="content_sortPagiBar clearfix"> <div class="sortPagiBar clearfix"> {include file="./product-sort.tpl"} {include file="./nbr-product-page.tpl"} </div> <div class="top-pagination-content clearfix"> {include file="./product-compare.tpl"} {include file="$tpl_dir./pagination.tpl"} </div> </div> {include file="./product-list.tpl" products=$products} <div class="content_sortPagiBar"> <div class="bottom-pagination-content clearfix"> {include file="./product-compare.tpl" paginationId='bottom'} {include file="./pagination.tpl" paginationId='bottom'} </div> </div> {/if} {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <div class="content_scene"> <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {if $category->description} <div class="cat_desc rte"> {if Tools::strlen($category->description) > 350} <div id="category_description_short">{$description_short}</div> <div id="category_description_full" class="unvisible">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category.link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div>{$category->description}</div> {/if} </div> {/if} </div> {else} <span class="page-heading{if (isset($subcategories) && !$products) || (isset($subcategories) && $products) || !isset($subcategories) && $products} product-listing{/if}"><span class="cat-name">{$category->name|escape:'html':'UTF-8'}{if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'}{/if}</span>{include file="$tpl_dir./category-count.tpl"}</span> {if isset($subcategories)} {if $category->description} <div class="cat_desc"> <span class="category-name"> {strip} {$category->name|escape:'html':'UTF-8'} {if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'} {/if} {/strip} </span> {if Tools::strlen($category->description) > 450} <div id="category_description_short" class="rte">{$description_short}</div> <div id="category_description_full" class="unvisible rte">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category->link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div class="rte">{$category->description}</div> {/if} </div> {/if} </div> {/if} {/if} <!-- Category image --> <div class="content_scene_cat_bg" {if $category->id_image}style="background:url({$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html':'UTF-8'}) 0 top no-repeat; background-size:contain; min-height:{$categorySize.height}px;" {/if}></div> {elseif $category->id} <p class="alert alert-warning">{l s='This category is currently unavailable.'}</p> {/if} {/if} Link to comment Share on other sites More sharing options...
Baalow59 Posted April 22, 2016 Author Share Posted April 22, 2016 Merci, par contre après vérification c'est déjà fait sur le fichier. {* * 2007-2015 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-2015 PrestaShop SA * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) * International Registered Trademark & Property of PrestaShop SA *} {include file="$tpl_dir./errors.tpl"} {if isset($category)} {if $category->id AND $category->active} <h1 class="page-heading{if (isset($subcategories) && !$products) || (isset($subcategories) && $products) || !isset($subcategories) && $products} product-listing{/if}"> <span class="cat-name"> {$category->name|escape:'html':'UTF-8'}{if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'}{/if} </span> {include file="$tpl_dir./category-count.tpl"} </h1> {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <div class="content_scene"> <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {if $category->description} <div class="cat-desc rte"> {if Tools::strlen($category->description) > 350} <div id="category_description_short">{$description_short}</div> <div id="category_description_full" class="unvisible">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category->link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div>{$category->description}</div> {/if} </div> {/if} </div> {else} <!-- Category image --> <div class="content_scene_cat_bg scene_cat"> {if $category->id_image} <div class="image"> <img class="img-responsive" src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html':'UTF-8'}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" /> </div> {/if} {if $category->description} <div class="cat-desc"> <div class="rte">{$category->description}</div> </div> {/if} </div> {/if} </div> {/if} {if isset($subcategories)} {if (isset($display_subcategories) && $display_subcategories eq 1) || !isset($display_subcategories) } <!-- Subcategories --> <div id="subcategories"> <h4 class="page-subheading">{l s='Subcategories'}</h4> <div class="clearfix row"> {foreach from=$subcategories item=subcategory} <div class="col-md-3 col-xs-6 col-sp-12"> <div class="subcategories scene_cat"> <div class="image"> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}" title="{$subcategory.name|escape:'html':'UTF-8'}" class="img"> {if $subcategory.id_image} <img class="replace-2x img-responsive" src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'category_default')|escape:'html':'UTF-8'}" alt=""/> {else} <img class="replace-2x img-responsive" src="{$img_cat_dir}{$lang_iso}-default-category_default.jpg" alt=""/> {/if} </a> </div> <h5 class="cat-name" ><a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}">{$subcategory.name|truncate:25:'...'|escape:'html':'UTF-8'|truncate:350}</a></h5> {if $subcategory.description} <div class="cat-desc">{$subcategory.description}</div> {/if} </div> </div> {/foreach} </div> </div> {/if} {/if} {if $products} {include file="$tpl_dir./sub/product/product-list-form.tpl"} {/if} {elseif $category->id} <p class="alert alert-warning">{l s='This category is currently unavailable.'}</p> {/if} {/if} exactement comme ton fichier ou alors je n'est pas compris. Link to comment Share on other sites More sharing options...
DeyDDy Posted April 23, 2016 Share Posted April 23, 2016 Bonjour, pas tout à fait le même, ci-dessous votre fichier avec la modification que vous souhaitiez {* * 2007-2015 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-2015 PrestaShop SA * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) * International Registered Trademark & Property of PrestaShop SA *} {include file="$tpl_dir./errors.tpl"} {if isset($category)} {if $category->id AND $category->active} <h1 class="page-heading{if (isset($subcategories) && !$products) || (isset($subcategories) && $products) || !isset($subcategories) && $products} product-listing{/if}"> <span class="cat-name"> {$category->name|escape:'html':'UTF-8'}{if isset($categoryNameComplement)} {$categoryNameComplement|escape:'html':'UTF-8'}{/if} </span> {include file="$tpl_dir./category-count.tpl"} </h1> {if isset($subcategories)} {if (isset($display_subcategories) && $display_subcategories eq 1) || !isset($display_subcategories) } <!-- Subcategories --> <div id="subcategories"> <h4 class="page-subheading">{l s='Subcategories'}</h4> <div class="clearfix row"> {foreach from=$subcategories item=subcategory} <div class="col-md-3 col-xs-6 col-sp-12"> <div class="subcategories scene_cat"> <div class="image"> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}" title="{$subcategory.name|escape:'html':'UTF-8'}" class="img"> {if $subcategory.id_image} <img class="replace-2x img-responsive" src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'category_default')|escape:'html':'UTF-8'}" alt=""/> {else} <img class="replace-2x img-responsive" src="{$img_cat_dir}{$lang_iso}-default-category_default.jpg" alt=""/> {/if} </a> </div> <h5 class="cat-name" ><a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'html':'UTF-8'}">{$subcategory.name|truncate:25:'...'|escape:'html':'UTF-8'|truncate:350}</a></h5> {if $subcategory.description} <div class="cat-desc">{$subcategory.description}</div> {/if} </div> </div> {/foreach} </div> </div> {/if} {/if} {if $products} {include file="$tpl_dir./sub/product/product-list-form.tpl"} {/if} {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <div class="content_scene"> <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {if $category->description} <div class="cat-desc rte"> {if Tools::strlen($category->description) > 350} <div id="category_description_short">{$description_short}</div> <div id="category_description_full" class="unvisible">{$category->description}</div> <a href="{$link->getCategoryLink($category->id_category, $category->link_rewrite)|escape:'html':'UTF-8'}" class="lnk_more">{l s='More'}</a> {else} <div>{$category->description}</div> {/if} </div> {/if} </div> {else} <!-- Category image --> <div class="content_scene_cat_bg scene_cat"> {if $category->id_image} <div class="image"> <img class="img-responsive" src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html':'UTF-8'}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" /> </div> {/if} {if $category->description} <div class="cat-desc"> <div class="rte">{$category->description}</div> </div> {/if} </div> {/if} </div> {/if} {elseif $category->id} <p class="alert alert-warning">{l s='This category is currently unavailable.'}</p> {/if} {/if} Link to comment Share on other sites More sharing options...
Baalow59 Posted April 24, 2016 Author Share Posted April 24, 2016 Hello, merci beaucoup ça fonctionne sans aucune erreur pour les catégories. http://www.matelas-morphee.fr/178-matelas-70-160 Encore merci à vous. comment clôture ton le poste ? merci. Link to comment Share on other sites More sharing options...
DeyDDy Posted April 24, 2016 Share Posted April 24, 2016 Bonjour, Cliquez sur le bouton "Editer" du premier post de votre topic ensuite le bouton "Utiliser l'éditeur complet" puis ajoutez la mention "Résolu" devant le titre du topic et enregister Bonne continuation 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