Is it possible to create a session from a custom prestashop file? I have restricted from the frontController browsing the store if a user does not have a session.
if (!$this->context->customer->isLogged() && $this->php_self != 'authentication' && $this->php_self != 'password'){
Tools::redirect('index.php?controller=authentication?back=my-account');
}
Now I need to access the certain methods of the tool from a custom file (if I include the file init.php first, check the status of my session and redirect me to login), there is a way to create a session before including this file?, Thanks.