piotrowski-s@hotmail.fr Posted April 3, 2016 Share Posted April 3, 2016 Hi, I created a new page (not using cms) because I want it to be a dynamique page. In my theme, I've selected that no column would be display on that page Even with that, it still display both column. Anykind of help will be much appreciated. In my tpl there is only the main page I want to display (no column). Link to comment Share on other sites More sharing options...
endriu107 Posted April 3, 2016 Share Posted April 3, 2016 How you created this page? Link to comment Share on other sites More sharing options...
piotrowski-s@hotmail.fr Posted April 3, 2016 Author Share Posted April 3, 2016 (edited) thank you for your reply, I've created 3 files : in root folder: anti-counterfeit.php <?php include(dirname(__FILE__).'/config/config.inc.php'); Tools::displayFileAsDeprecated(); include(dirname(__FILE__).'/header.php'); $smarty->display(_PS_THEME_DIR_.'anti-counterfeit.tpl'); include(dirname(__FILE__).'/footer.php'); Then in controller AntiCounterfeitController.php <?php /* The classname here will be the name of the controller */ class AntiCounterfeitController extends FrontController{ public function init(){ parent::init(); } public function initContent(){ parent::initContent(); $this->setTemplate(_PS_THEME_DIR_.'anti-counterfeit.tpl'); } /* The following code portion is optional. /* Remove the double-slashes to activate the portion /* if you want to use external stylesheet and JavaScript for the page. /* Create the CSS and JS files in the css and js directories of the theme accordingly */ //public function setMedia(){ //parent::setMedia(); //$this->addCSS(_THEME_CSS_DIR_.'custom-page.css'); //$this->addJS(_THEME_JS_DIR_.'custom-page.js'); //} } Then the tpl in the theme folder (actually it is empty just a "test" text to be displayed (it works), but with both column, and I want none of them. Edited April 3, 2016 by piotrowski-s@hotmail.fr (see edit history) Link to comment Share on other sites More sharing options...
endriu107 Posted April 3, 2016 Share Posted April 3, 2016 Change public function init(){ parent::init();to public function init(){ $this->display_column_left = false; $this->display_column_right = false; parent::init(); 1 Link to comment Share on other sites More sharing options...
piotrowski-s@hotmail.fr Posted April 3, 2016 Author Share Posted April 3, 2016 thank you very much? It was really helpfull. 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