r2mi.gaillard Posted June 18, 2013 Share Posted June 18, 2013 Hello, I would like to know if it is possible to add some images or text in a product page. Because I would like to put an images to the top of one of my product pages. I know how to create a normal web pages in my site with the CMS but I don't know how to include a CMS or an images on a product pages. Can you tell me if it's possible or not ? Link to comment Share on other sites More sharing options...
presta4you.com Posted June 18, 2013 Share Posted June 18, 2013 With standard prestashop i not posibble, but maybe somebody created that module. Look inside this category http://www.prestashop.com/forums/forum/144-free-modules/ Link to comment Share on other sites More sharing options...
amr.rs Posted June 19, 2013 Share Posted June 19, 2013 Hello, I would like to know if it is possible to add some images or text in a product page. Because I would like to put an images to the top of one of my product pages. I know how to create a normal web pages in my site with the CMS but I don't know how to include a CMS or an images on a product pages. Can you tell me if it's possible or not ? You can't simply include CMS pages inside Product page but you can include it in all pages. Also do you want to have those images displayed in all product pages or in only certain pages? Link to comment Share on other sites More sharing options...
r2mi.gaillard Posted June 19, 2013 Author Share Posted June 19, 2013 You can't simply include CMS pages inside Product page but you can include it in all pages. Also do you want to have those images displayed in all product pages or in only certain pages? I would like to display it only in certain pages, it is possible or not ? Link to comment Share on other sites More sharing options...
ariom Posted June 26, 2013 Share Posted June 26, 2013 Hi r2migaillard, i have a workaround solution for 1.4.xx (working on 1.4.7.3) Wich Prestashop version you use? to display an image on the product page,don't need to insert a cms page, in your theme product.tpl insert this function where you want the image be displayed {if $page_name == 'product' AND $smarty.get.id_product} {if in_array($id_product, array(13,14,15,20,28,29,30,41))} <YOUR HTML HERE>insert the image you want to display on product page 13,14,15,20,28,29,30,41 {elseif $page_name == 'product' AND $smarty.get.id_product} {if in_array($id_product, array(23,34,25,40,28,22,38,71))} <YOUR HTML HERE> {/if} {/if} If it is not working, you have also to override frontController.php to get the variable id_product by the header class FrontController extends FrontControllerCore { public function displayHeader() { $pathinfo = pathinfo(__FILE__); $page_name = basename($_SERVER['PHP_SELF'], '.'.$pathinfo['extension']); $page_name = (preg_match('/^[0-9]/', $page_name)) ? 'page_'.$page_name : $page_name; if ($page_name == 'product' AND isset($_GET['id_product'])) { $product = new Product($_GET['id_product'], false, intval(self::$cookie->id_lang)); if (Validate::isLoadedObject($product)) self::$smarty->assign('product_name', $product->name); } parent::displayHeader(); } } changing the variables and insering the right values, i think it can be used also to insert different cms content on different product pages Hope it helps, Ariom 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