Logout function
Posted: Mon Nov 19, 2012 5:05 pm
Hello
!
I'm actually doing an integration of Hesk in a script that I'm developing myself.
Login and password will be the same on my script and on Hesk.
I create the necessary cookies with the following code :
Login works properly, but I don't seem to get disconnection to work. I've looked at Hesk's source code and try those methods :
None of them work, when I go to the page hesk/admin/admin_main.php I'm still logged in 
Did you have an idea ? Thank you in advance !

I'm actually doing an integration of Hesk in a script that I'm developing myself.
Login and password will be the same on my script and on Hesk.
I create the necessary cookies with the following code :
Code: Select all
setcookie('hesk_username', "$user", strtotime('+1 year'));
setcookie('hesk_p', "$pass_enc", strtotime('+1 year'));
Code: Select all
<?php
setcookie('hesk_p', "");
?>
Code: Select all
<?php
setcookie('hesk_username', "");
setcookie('hesk_p', "");
?>
Code: Select all
<?php
setcookie('hesk_username', "", time() - 3600);
setcookie('hesk_p', "", time() - 3600);
?>

Did you have an idea ? Thank you in advance !