to make an information page protected, I've decided to go the easy way :
make the sort order of the page negative (like -2)
then open catalog/controller/information/information.php
find this line (~ #23):
Code: Select all
$information_info = $this->model_catalog_information->getInformation($information_id);
Code: Select all
/************** if sort_order is netative and user is not logged, we redirect him to be logged *********/
if (!$this->customer->isLogged() && ($information_info['sort_order'] <0)) {
$this->session->data['redirect'] = HTTPS_SERVER . 'index.php?route='.$this->request->get['route'];
if (isset($this->request->get['information_id'])) {
$this->session->data['redirect'] = $this->session->data['redirect'].'&information_id='.$this->request->get['information_id'];
}
$this->redirect(HTTPS_SERVER . 'index.php?route=account/login');
}
/**************** end mod ************/
still in the information menu, but you'll be redirect to login...