Sign out Page Encrypted Messenger PHP

Sign out Page

Encrypted Messenger PHP


The session_unset() function frees all session variables currently registered.


session_destroy() destroys all of the data associated with the current session.
It does not unset any of the global variables associated with the session, or unset the session cookie.
To use the session variables again, session_start() has to be called.


The setcookie() function defines a cookie to be sent along with the rest of the HTTP headers.
A cookie is often used to identify a user.
A cookie is a small file that the server embeds on the user’s computer.
Each time the same computer requests a page with a browser, it will send the cookie too.
With PHP, you can both create and retrieve cookie values.
The name of the cookie is automatically assigned to a variable of the same name.
For example, if a cookie was sent with the name “user”, a variable is automatically created called $user, containing the cookie value.
Note: The setcookie() function must appear BEFORE thetag.
Note: The value of the cookie is automatically URLencoded when sending the cookie, and automatically decoded when received (to prevent URLencoding, use setrawcookie() instead)

Create a file named index.php

function secured_error () { die("Secured By Omid Bahrami"); }

require '../secured/secured-database.php';
require '../secured/secured-encryption.php';




setcookie( XFIRSTNX , "" , 7 , "/" , XDOMAINX , true , true );
setcookie( XSECONDNX , "" , 7 , "/" , XDOMAINX , true , true );
setcookie( XTHIRDNX , "" , 7 , "/" , XDOMAINX , true , true );


Full structure is available at Encrypted Messenger PHP