coindespetits Posted December 3, 2014 Share Posted December 3, 2014 (edited) Bonsoir, J'aurais sérieusement besoin d 'un coup de main, lorsqu'un visiteur clique sur sur l'une des catégorie, il rencontre une page blanche... Je vous met le message : Uncaught exception 'SmartyCompilerException' with message 'Syntax Error in template "/homepages/2/d516531929/htdocs/themes/test/category.tpl" on line 90 "" unclosed {if} tag' in /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php:667 Stack trace: #0 /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_smartytemplatecompiler.php(118): Smarty_Internal_TemplateCompilerBase->trigger_template_error('unclosed {if} t...') #1 /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php(206): Smarty_Internal_SmartyTemplateCompiler->doCompile('{*\n* 2007-2013 ...') #2 /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_template.php(187): Smarty_Internal_TemplateCompilerBase->compileTemplate(Object(Smarty_Internal_Template)) #3 /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_templatebase.php(155): Smarty_Internal_Template->compileTemplateSource() #4 /homepages/2/ in /homepages/2/d516531929/htdocs/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php on line 667 Si quelqu'un peut m'aider svp, j'ai raté des ventes aujourd'hui Edited December 7, 2014 by coindespetits (see edit history) Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 voici mon fichier category.tpl : {include file="$tpl_dir./breadcrumb.tpl"}{include file="$tpl_dir./errors.tpl"}{if isset($category)} {if $category->id AND $category->active} <h1> {strip} {$category->name|escape:'htmlall':'UTF-8'} {if isset($categoryNameComplement)} {$categoryNameComplement|escape:'htmlall':'UTF-8'} {/if} {/strip} </h1> <div class="resumecat category-product-count"> {include file="$tpl_dir./category-count.tpl"} </div> {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {else} <!-- Category image --> {if $category->id_image} <div class="align_center"> <img src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html'}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" width="{$categorySize.width}" height="{$categorySize.height}" /> </div> {/if} {/if} {if $category->description} <div class="cat_desc"> <p>{$category->description}</p> </div> {/if} {if $products} <div class="content_sortPagiBar"> {include file="$tpl_dir./pagination.tpl"} <div class="sortPagiBar clearfix"> {include file="./product-sort.tpl"} {include file="./product-compare.tpl"} {include file="./nbr-product-page.tpl"} </div> </div> {include file="./product-list.tpl" products=$products} <div class="content_sortPagiBar"> <div class="sortPagiBar clearfix"> {include file="./product-sort.tpl" paginationId='bottom'} {include file="./product-compare.tpl" paginationId='bottom'} {include file="./nbr-product-page.tpl" paginationId='bottom'} </div> {include file="./pagination.tpl" paginationId='bottom'} </div> {/if} {elseif $category->id} <p class="warning">{l s='This category is currently unavailable.'}</p> {/if}{/if} Link to comment Share on other sites More sharing options...
coeos.pro Posted December 3, 2014 Share Posted December 3, 2014 compte les if ouvrant et fermant: ... unclosed {if} tag ... Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 Merci beaucoup pour votre réponse. J'ai l'impression que le soucis viens d'ici : {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {else} <!-- Category image --> {if $category->id_image} <div class="align_center"> <img src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html'}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" width="{$categorySize.width}" height="{$categorySize.height}" /> </div> {/if} {/if} Je sais pas vraiment ou le mettre Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 est ce vraiment cela ? car mon category.tpl est point pour point le même que celui du thème par default Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 J'ai également remplacer mon category.tpl par le category.tpl du thème par default sans succès... Link to comment Share on other sites More sharing options...
loulou66 Posted December 3, 2014 Share Posted December 3, 2014 (edited) Coucou Modifier le {/if} est a la fin du fichier ^^ sinon vérifie aussi dans les fichiers include {include file="$tpl_dir./category-count.tpl"} et {include file="$tpl_dir./scenes.tpl" scenes=$scenes} il y en a d'autres vers la fin de ton fichier category.tpl {if $products} <div class="content_sortPagiBar"> {include file="$tpl_dir./pagination.tpl"} <div class="sortPagiBar clearfix"> {include file="./product-sort.tpl"} {include file="./product-compare.tpl"} {include file="./nbr-product-page.tpl"} </div> </div> {include file="./product-list.tpl" products=$products} <div class="content_sortPagiBar"> <div class="sortPagiBar clearfix"> {include file="./product-sort.tpl" paginationId='bottom'} {include file="./product-compare.tpl" paginationId='bottom'} {include file="./nbr-product-page.tpl" paginationId='bottom'} </div> {include file="./pagination.tpl" paginationId='bottom'} </div> {/if} @++ Loulou66 Edited December 3, 2014 by loulou66 (see edit history) Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 Bonsoir, merci pour la réponse ! Je me souvient hier soir avoir tenté de modifier la taille du texte description des catégories... J eme demande si l'erreur est pas du côté de : {if $scenes || $category->description || $category->id_image} <div class="content_scene_cat"> {if $scenes} <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {else} <!-- Category image --> {if $category->id_image} <div class="align_center"> <img src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category_default')|escape:'html'}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" width="{$categorySize.width}" height="{$categorySize.height}" /> </div> {/if} {/if} {if $category->description} <div class="cat_desc"> <p>{$category->description}</p> </div> Est ce que l'erreur peut survenir 24h après une modif ? Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 voici la manif que j'ia effectué hier : allez à la ligne 59 et remplacez ceci : {if $category->description} <div class="cat_desc"> {if strlen($category->description) > 120} <p id="category_description_short">{$category->description|truncate:120}</p> <p id="category_description_full" style="display:none">{$category->description}</p> <a href="#" onclick="$('#category_description_short').hide(); $('#category_description_full').show(); $(this).hide(); return false;" class="lnk_more">{l s='More'}</a> {else} <p>{$category->description}</p> {/if} </div> {/if} par cela : {if $category->description} <div class="cat_desc"> <p>{$category->description}</p> </div> {/if} Link to comment Share on other sites More sharing options...
coindespetits Posted December 3, 2014 Author Share Posted December 3, 2014 est ce que quelqu'un pourrait me donner le code category.tpl de son thème par défault ? Je suis sous prestashop 1.5 Link to comment Share on other sites More sharing options...
loulou66 Posted December 3, 2014 Share Posted December 3, 2014 coucou ta modif me semble correct voila le category.tpl de la 1.5.6.2 theme default https://copy.com/uLwIxylaJM6KdBEZ @++ Loulou66 Link to comment Share on other sites More sharing options...
coindespetits Posted December 7, 2014 Author Share Posted December 7, 2014 Merci à tous pour votre aide, j'ai résolu mon soucis 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