shana0780 Posted July 1, 2012 Share Posted July 1, 2012 (edited) Bonjour, J'utilise le thème Matrice et prestashop 1.4.8 J'ai encodé quelques catégories sans y mettre d'images. Normalement, je devrais voir l'image par défaut "pas d'images" mais à chaque catégorie, le programme a créé une image (que je n'ai bien sûr pas mis) et du coup j'ai un problème au niveau de l'affichage. Un exemple de pages http://www.unmaxdescrap.fr/1-home et un exemple de lien d'images qui a été créé http://www.unmaxdesc...accessoires.jpg plutôt que d'avoir mis l'image par défaut. Quelqu'un peut-il me dire ce qu'il faut faire ? Edited July 6, 2012 by shana0780 (see edit history) Link to comment Share on other sites More sharing options...
shana0780 Posted July 3, 2012 Author Share Posted July 3, 2012 et je viens d'essayer d'ajouter une image mais là aussi il me transforme mon lien en une image qui n'existe pas http://www.unmaxdescrap.fr/c/22-medium/test.jpg Voici le fichier category.tpl si quelqu'un sait me dire où se trouve l'erreur {include file="$tpl_dir./breadcrumb.tpl"} <div class="cms"> {include file="$tpl_dir./errors.tpl"} <!-- Left --> {if isset($category)} <div class="list_product"> {if $category->id AND $category->active} {if $scenes} <!-- Scenes --> {include file="$tpl_dir./scenes.tpl" scenes=$scenes} {/if} <!-- Category image --> {if $category->id_image} <div class="align_center"> <img src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category')}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage" width="{$categorySize.width}" height="{$categorySize.height}" /> </div> {/if} <h1 class="category_title"> {strip} {$category->name|escape:'htmlall':'UTF-8'} <span> {if $nb_products == 0}{l s='There are no products.'} {else} {if $nb_products == 1}{l s='There is'}{else}{l s='There are'}{/if} {$nb_products} {if $nb_products == 1}{l s='product.'}{else}{l s='products.'}{/if} {/if} </span> {/strip} </h1> {if $category->description} <div class="cat_desc">{$category->description}</div> {/if} {if isset($subcategories)} <!-- Subcategories --> <div id="subcategories"> <ul> {foreach from=$subcategories item=subcategory} <ol> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'htmlall':'UTF-8'}" title="{$subcategory.name|escape:'htmlall':'UTF-8'}"> {if $subcategory.id_image} <img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'medium')}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {else} <img src="{$img_cat_dir}default-medium.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {/if} </a> <li> <h6> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'htmlall':'UTF-8'}"> {$subcategory.name|escape:'htmlall':'UTF-8'} </a> </h6> <span>{$subcategory.description|escape:'htmlall':'UTF-8'|truncate:100:'...'}</span> </li> </ol> {/foreach} </ul> </div> {/if} </div> {if $products} <div class="list_categorie_product"> <li id="productsSortForm"> {if $products} {include file="$tpl_dir./product-sort.tpl"} {include file="$tpl_dir./product-compare.tpl"} {/if} </li> {include file="$tpl_dir./product-list.tpl" products=$products} {if $products} {include file="$tpl_dir./pagination.tpl"} {/if} </div> {elseif !isset($subcategories)} <p class="warning">{l s='There are no products in this category.'}</p> {/if} {elseif $category->id} <p class="warning">{l s='This category is currently unavailable.'}</p> {/if} {/if} </div> Link to comment Share on other sites More sharing options...
shana0780 Posted July 6, 2012 Author Share Posted July 6, 2012 j'ai le même problème d'images dans le fichier manufacturer.tpl Toujours personne qui peut me dire comment faire ? Link to comment Share on other sites More sharing options...
Stéphane Chonez Posted July 6, 2012 Share Posted July 6, 2012 Salut Shana, 2 pistes... régénérer les images ou désactiver les url simplifiées... si c'est les url simplifiées, cela provient certainement de ton fichier .htaccess qui s'est mal configuré.... à voir Link to comment Share on other sites More sharing options...
shana0780 Posted July 6, 2012 Author Share Posted July 6, 2012 (edited) Bonjour Stéphane, Merci pour ta réponse. Il s'agit en effet de l'url simplifié. Je l'ai désactivé et là l'image est apparue (mais décalée du cadre). Par contre pour les images fabricants, ça n'a rien changé. Voici ce que comprend le fichier htaccess (pour info le site est sous OVH) SetEnv PHP_VER 5_3SetEnv REGISTER_GLOBALS 0 RewriteEngine on RewriteBase / # .htaccess automaticaly generated by PrestaShop e-commerce open-source solution # WARNING: PLEASE DO NOT MODIFY THIS FILE MANUALLY. IF NECESSARY, ADD YOUR SPECIFIC CONFIGURATION WITH THE HTACCESS GENERATOR IN BACK OFFICE # http://www.prestashop.com - http://www.prestashop.com/forums <IfModule mod_rewrite.c> # URL rewriting module activation RewriteEngine on # URL rewriting rules RewriteRule ^api/?(.*)$ /webservice/dispatcher.php?url=$1 [QSA,L] RewriteRule ^([a-z0-9]+)\-([a-z0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2$3.jpg [L] RewriteRule ^([0-9]+)\-([0-9]+)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2.jpg [L] RewriteRule ^([0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/c/$1$2.jpg [L] RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L] RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]* /category.php?id_category=$1 [QSA,L] RewriteRule ^[a-zA-Z0-9-]*/([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L] RewriteRule ^([0-9]+)__([a-zA-Z0-9-]*) /supplier.php?id_supplier=$1 [QSA,L] RewriteRule ^([0-9]+)_([a-zA-Z0-9-]*) /manufacturer.php?id_manufacturer=$1 [QSA,L] RewriteRule ^content/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms=$1 [QSA,L] RewriteRule ^content/category/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms_category=$1 [QSA,L] RewriteRule ^page-non-trouvee$ /404.php [QSA,L] RewriteRule ^adresse$ /address.php [QSA,L] RewriteRule ^adresses$ /addresses.php [QSA,L] RewriteRule ^authentification$ /authentication.php [QSA,L] RewriteRule ^meilleures-ventes$ /best-sales.php [QSA,L] RewriteRule ^panier$ /cart.php [QSA,L] RewriteRule ^contactez-nous$ /contact-form.php [QSA,L] RewriteRule ^bons-de-reduction$ /discount.php [QSA,L] RewriteRule ^suivi-commande-invite$ /guest-tracking.php [QSA,L] RewriteRule ^historique-des-commandes$ /history.php [QSA,L] RewriteRule ^identite$ /identity.php [QSA,L] RewriteRule ^fabricants$ /manufacturer.php [QSA,L] RewriteRule ^mon-compte$ /my-account.php [QSA,L] RewriteRule ^nouveaux-produits$ /new-products.php [QSA,L] RewriteRule ^commande$ /order.php [QSA,L] RewriteRule ^details-de-la-commande$ /order-follow.php [QSA,L] RewriteRule ^commande-rapide$ /order-opc.php [QSA,L] RewriteRule ^avoirs$ /order-slip.php [QSA,L] RewriteRule ^mot-de-passe-oublie$ /password.php [QSA,L] RewriteRule ^promotions$ /prices-drop.php [QSA,L] RewriteRule ^recherche$ /search.php [QSA,L] RewriteRule ^plan-du-site$ /sitemap.php [QSA,L] RewriteRule ^magasins$ /stores.php [QSA,L] RewriteRule ^fournisseurs$ /supplier.php [QSA,L] </IfModule> # Catch 404 errors ErrorDocument 404 /404.php # protecttpl <Files ~ "\.tpl$"> Order allow,deny Deny from all </Files> Edited July 6, 2012 by shana0780 (see edit history) Link to comment Share on other sites More sharing options...
shana0780 Posted July 6, 2012 Author Share Posted July 6, 2012 (edited) J'ai trouvé sur le forum OVH le bon fichier mais l'image est décalée voir sur cette page http://www.unmaxdesc...icles-a-decorer Je suppose qu'il faut changer quelque chose dans le fichier category.tpl mais je ne vois pas quoi. # .htaccess automaticaly generated by PrestaShop e-commerce open-source solution # WARNING: PLEASE DO NOT MODIFY THIS FILE MANUALLY. IF NECESSARY, ADD YOUR SPECIFIC CONFIGURATION WITH THE HTACCESS GENERATOR IN BACK OFFICE # http://www.prestashop.com - http://www.prestashop.com/forums SetEnv PHP_VER 5 <IfModule mod_rewrite.c> # URL rewriting module activation RewriteEngine on # URL rewriting rules RewriteRule ^api/?(.*)$ /webservice/dispatcher.php?url=$1 [QSA,L] RewriteRule ^([a-z0-9]+)\-([a-z0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2$3.jpg [L] RewriteRule ^([0-9]+)\-([0-9]+)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2.jpg [L] RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$1$2.jpg [L] RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$1$2$3.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$1$2$3$4.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$1$2$3$4$5.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8.jpg [L] RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9.jpg [L] RewriteRule ^c/([0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/c/$1$2.jpg [L] RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L] RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]* /category.php?id_category=$1 [QSA,L] RewriteRule ^[a-zA-Z0-9-]*/([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L] RewriteRule ^([0-9]+)__([a-zA-Z0-9-]*) /supplier.php?id_supplier=$1 [QSA,L] RewriteRule ^([0-9]+)_([a-zA-Z0-9-]*) /manufacturer.php?id_manufacturer=$1 [QSA,L] RewriteRule ^content/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms=$1 [QSA,L] RewriteRule ^content/category/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms_category=$1 [QSA,L] RewriteRule ^([0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/c/$1$2.jpg [L] RewriteRule ^page-non-trouvee$ /404.php [QSA,L] RewriteRule ^adresse$ /address.php [QSA,L] RewriteRule ^adresses$ /addresses.php [QSA,L] RewriteRule ^authentification$ /authentication.php [QSA,L] RewriteRule ^meilleures-ventes$ /best-sales.php [QSA,L] RewriteRule ^panier$ /cart.php [QSA,L] RewriteRule ^contactez-nous$ /contact-form.php [QSA,L] RewriteRule ^bons-de-reduction$ /discount.php [QSA,L] RewriteRule ^suivi-commande-invite$ /guest-tracking.php [QSA,L] RewriteRule ^historique-des-commandes$ /history.php [QSA,L] RewriteRule ^identite$ /identity.php [QSA,L] RewriteRule ^fabricants$ /manufacturer.php [QSA,L] RewriteRule ^mon-compte$ /my-account.php [QSA,L] RewriteRule ^nouveaux-produits$ /new-products.php [QSA,L] RewriteRule ^commande$ /order.php [QSA,L] RewriteRule ^details-de-la-commande$ /order-follow.php [QSA,L] RewriteRule ^commande-rapide$ /order-opc.php [QSA,L] RewriteRule ^avoirs$ /order-slip.php [QSA,L] RewriteRule ^mot-de-passe-oublie$ /password.php [QSA,L] RewriteRule ^promotions$ /prices-drop.php [QSA,L] RewriteRule ^recherche$ /search.php [QSA,L] RewriteRule ^plan-du-site$ /sitemap.php [QSA,L] RewriteRule ^magasins$ /stores.php [QSA,L] RewriteRule ^fournisseurs$ /supplier.php [QSA,L] </IfModule> # Catch 404 errors ErrorDocument 404 /404.php <IfModule mod_expires.c> ExpiresActive On ExpiresByType image/gif "access plus 1 month" ExpiresByType image/jpeg "access plus 1 month" ExpiresByType image/png "access plus 1 month" ExpiresByType text/css "access plus 1 week" ExpiresByType text/javascript "access plus 1 week" ExpiresByType application/javascript "access plus 1 week" ExpiresByType application/x-javascript "access plus 1 week" ExpiresByType image/x-icon "access plus 1 year" </IfModule> FileETag INode MTime Size <IfModule mod_deflate.c> AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE text/javascript AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript </IfModule> Edited July 6, 2012 by shana0780 (see edit history) Link to comment Share on other sites More sharing options...
Stéphane Chonez Posted July 6, 2012 Share Posted July 6, 2012 vous avez un soucis de calage dans votre thème... j'ai repéré ceci : div.list_product { float: left; margin-bottom: 1em; width: 890px; } la largeur du block fait 890px alors que l'espace disponible est de 670px puisqu'il est parent de : div.cms { float: right; margin-top: 1.8em; padding-bottom: 2em; width: 670px; } donc déjà remettre à 670px div.list_product { float: left; margin-bottom: 1em; width: 670px; } ça se passe dans le fichier category.css ligne 2 dites moi si ça améliore l'affichage! Link to comment Share on other sites More sharing options...
shana0780 Posted July 6, 2012 Author Share Posted July 6, 2012 Oui merci beaucoup, çà fonctionne en effet. Je venais de le repérer avec Firefox Il me reste à faire des images à la bonne taille :-) 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