Jump to content

Add new cookie or session after login


Tanker

Recommended Posts

When an admin logs in I want to add a new custom session my own variable or cookie, so that I can use it in the front end of the site, I havn't been able t do that even when I change the AdminLogiController, I added my cookie after:

 

$cookie->write();

//My Cookie

setcookie('X', 'z', time()+3600, '/', null, 0);

 

then I want to retrieve that cookie en the front end... but no luck.

 

The idea is that when an admin logs in I want to set a cookie/session so later can be use in the front end.

So how can I do this?

 

ps. I'm new to prestashop, only 2 days working on it...

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...