LeGhe Posted April 21, 2010 Share Posted April 21, 2010 Bonsoir.Pensez-vous qu'il soit possible d'afficher une image de fond (ou un bandeau) spécifique à chaque catégorie ?Par exemple, je suis sur la catégorie Randonnée, et l'image de fond (ou le bandeau) représente une paire de godasses, sur la catégorie Kenya, c'est un éléphant en fond d'écran, etc...Par où attaquer le bébé ?Merci !!Topic déplacé -yoya971 Link to comment Share on other sites More sharing options...
Divine Posted April 22, 2010 Share Posted April 22, 2010 Hello,Oui c'est faisable en ajoutant une condition. Tu peux utiliser les ID des catégories pour cela.Je pense que cela doit se passer dans le fichier categorie.tplA confirmer... Link to comment Share on other sites More sharing options...
LeGhe Posted June 8, 2010 Author Share Posted June 8, 2010 Je me suis mal exprimé en fait.Je voudrais que l'image de fond d'un PRODUIT soit celle de la CATEGORIE en cours.Mais je n'arrive pas appeler l'id_category depuis le header d'une page produit... Link to comment Share on other sites More sharing options...
Divine Posted June 8, 2010 Share Posted June 8, 2010 C'est donc dans le fichier product.tpl que tu dois effectuer tes modifications. Je crois que la bonne variable à utiliser est id_category_current Link to comment Share on other sites More sharing options...
LeGhe Posted June 9, 2010 Author Share Posted June 9, 2010 Oui, mais cette variable est inconnu du header, et une background image ne fonctionnera que dans le header. Dans product.tpl, l'image ne reste que sur la colonne centrale... Link to comment Share on other sites More sharing options...
Atch Posted June 9, 2010 Share Posted June 9, 2010 Salut,la variable {$currentCategoryId} fonctionne dans le header...J'avais essayé un truc il y a un moment pour une boutique test, et tu verras ça fonctionne :http://astushop.atchworks.com/V++Atch Link to comment Share on other sites More sharing options...
LeGhe Posted June 9, 2010 Author Share Posted June 9, 2010 Merci pour ta réponse.Ben en dernière version 1.3.1, elle fonctionne plus !Le smarty debug ne l'indique pas non plus... Peut-on l'appeler ? Link to comment Share on other sites More sharing options...
Atch Posted June 9, 2010 Share Posted June 9, 2010 T'es sure?Je viens de tester sur la 1.3.1 et la 1.3.11 et dans les deux cas la variable {$currentCategoryId} est disponnible (sauf dans l'index biensure)V++Atch Link to comment Share on other sites More sharing options...
LeGhe Posted June 9, 2010 Author Share Posted June 9, 2010 debug en header.tpl, et appel de page produit :Smarty Debug Consoleincluded templates & config files (load time in seconds):no templates includedassigned template variables:{$HOOK_HEADER} "<link rel="canonical" href="http://ww..."{$HOOK_LEFT_COLUMN} "<!-- Block links module --> <div id=..."{$HOOK_TOP} "<!-- Block user information module HE..."{$SCRIPT_NAME} "/prestashop/product.php"{$base_dir} "http://127.0.0.1/prestashop/"{$base_dir_ssl} "http://127.0.0.1/prestashop/"{$blocklink_link} Array (4)id => "3"url => "http://www.autourdumonde.biz/content/..."newWindow => "0"text_2 => "Les sites qu'on aime"{$blocklink_links} Array (3)0 => Array (4) id => "1" url => "http://www.autourdumonde.biz/content/..." newWindow => "0" text_2 => "Bien choisir son guide de voyage"1 => Array (4) id => "2" url => "http://www.autourdumonde.biz/content/..." newWindow => "0" text_2 => "Les Chtis voyageurs"2 => Array (4) id => "3" url => "http://www.autourdumonde.biz/content/..." newWindow => "0" text_2 => "Les sites qu'on aime"{$canonical_url} "http://www.autourdumonde.biz/prestash..."{$cart} Cart Object (13)->id = 3->id_address_delivery = "0"->id_address_invoice = "0"->id_currency = "1"->id_customer = "0"->id_guest = "6"->id_lang = "2"->id_carrier = null->recyclable = "1"->gift = "0"->gift_message = ""->date_add = "2010-06-08 15:45:34"->date_upd = "2010-06-08 15:45:44"{$cart_qties} 0{$come_from} "http://127.0.0.1/prestashop/product.p..."{$content_dir} "http://127.0.0.1/prestashop/"{$content_only} 0{$cookie} Cookie Object (0){$css_dir} "http://127.0.0.1/prestashop/themes/pr..."{$css_files} Array (3)/prestashop/css/thickbox.css => "screen"/prestashop/css/jqzoom.css => "screen"/prestashop/themes/prestashop/css/global.css => "all"{$currencies} Array (1)0 => Array (9) id_currency => "1" name => "Euro" iso_code => "EUR" sign => "€" blank => "1" format => "2" decimals => "1" conversion_rate => "1.000000" deleted => "0"{$currency} Currency Object (9)->id = 1->name = "Euro"->iso_code = "EUR"->sign = "€"->blank = "1"->conversion_rate = "1.000000"->deleted = "0"->format = "2"->decimals = "1"{$customerName} false{$description_short} ""{$firstName} false{$id_currency_cookie} 1{$img_cat_dir} "http://127.0.0.1/prestashop/img/c/"{$img_col_dir} "http://127.0.0.1/prestashop/img/co/"{$img_dir} "http://127.0.0.1/prestashop/themes/pr..."{$img_lang_dir} "http://127.0.0.1/prestashop/img/l/"{$img_manu_dir} "http://127.0.0.1/prestashop/img/m/"{$img_prod_dir} "http://127.0.0.1/prestashop/img/p/"{$img_ps_dir} "http://127.0.0.1/prestashop/img/"{$img_ship_dir} "http://127.0.0.1/prestashop/img/s/"{$img_sup_dir} "http://127.0.0.1/prestashop/img/su/"{$js_dir} "http://127.0.0.1/prestashop/themes/pr..."{$js_files} Array (7)0 => "/prestashop/js/jquery/thickbox-modifi..."1 => "/prestashop/js/jquery/jquery.idTabs.m..."2 => "/prestashop/js/jquery/jquery.scrollto.js"3 => "/prestashop/js/jquery/jquery.serialSc..."4 => "/prestashop/themes/prestashop/js/tool..."5 => "/prestashop/themes/prestashop/js/prod..."6 => "/prestashop/js/jquery/jquery.jqzoom.js"{$lang} "text_2"{$lang_iso} "fr"{$languages} Array (1)0 => Array (4) id_lang => 2 name => "Français (French)" iso_code => "fr" active => 1{$lastName} false{$link} Link Object (0){$logged} false{$mail_dir} "/prestashop/mails/"{$meta_description} "A l'orée des années 2000, un jeune ..."{$meta_keywords} "Nullarbor,David Fauquemberg,Australie..."{$meta_title} "Nullarbor"{$module_dir} "/prestashop/modules/blockuserinfo/"{$module_template_dir} "/prestashop/modules/blockuserinfo/"{$modules_dir} "/prestashop/modules/"{$name} "Nullarbor"{$navigationPipe} ">"{$page_name} "product"{$pic_dir} "http://127.0.0.1/prestashop/upload/"{$priceDisplay} 0{$priceDisplayPrecision} 2{$request_uri} "/prestashop/product.php?id_product=12559"{$roundMode} 2{$shop_name} "Autour du Monde"{$static_token} "cf9284975caebf44eedc7af2b67a41e6"{$title} "Bloc lien"{$token} "1eb2ff2596ca69d614bdb0d1606a9efd"{$tpl_dir} "D:\xampplite\htdocs\prestashop/themes..."{$url} false{$use_taxes} 1assigned config file variables (outer template scope):{#files#} Array (0){#vars#} Array (0) Link to comment Share on other sites More sharing options...
Atch Posted June 9, 2010 Share Posted June 9, 2010 J'ai envi de dire "pas de bol"....Je viens de contrôler, je l'ai bien de dispo meme dans la page produit...Essaye avec la template par défaut prestashop et tu constateras, normalement, la présence de cette balise.V++Atch Link to comment Share on other sites More sharing options...
Ether Création Posted September 12, 2012 Share Posted September 12, 2012 Bonjour, SI quelqu'un à besoin nous venons de sortir un module qui devrait faire l'affaire : http://www.prestashop.com/forums/topic/186983-ajouter-des-images-de-fond-sur-page-accueil-produits-categories/ Cordialement, Arthur 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