Mr.Curiosity Posted July 8, 2011 Share Posted July 8, 2011 just wonder, is there a way to create a page that needed a password to open them? Link to comment Share on other sites More sharing options...
shokinro Posted July 8, 2011 Share Posted July 8, 2011 create a page to check authentication by checking $cookie objectadd following code at beginning of your page if (!$cookie->isLogged()) Tools::reditect("authentication.php?back=yournewpage"); if you are using 1.4x, it is better to follow new pages structure, use Page Controller.in that case, you only need to set following in your new page controllerhere is the example of history public function __construct() { $this->auth = true; $this->php_self = 'history.php'; $this->authRedirection = 'history.php'; .... Link to comment Share on other sites More sharing options...
Mr.Curiosity Posted July 8, 2011 Author Share Posted July 8, 2011 can I make certain CMS page to be password protected? so we have to login to view them.and where can I find page controller? did you mean in / sites / mywebsite.com / www / [controllers] Link to comment Share on other sites More sharing options...
shokinro Posted July 8, 2011 Share Posted July 8, 2011 yes, the page controller is under following folderYourStoreRoot/controllersbut if you only want to apply it on some CMS page, you will need to check the CMS id first then set authentication or redirect Link to comment Share on other sites More sharing options...
Recommended Posts