Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa PHP How to destory session in PHP
Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


Deepak Kumar
How to destory session in PHP
1 Answer(s)      4 years and a month ago
Posted in : PHP


Hi,

I have to write a php page for logout. Please tell me what i should write?

Thanks


Advertisement
View Answers

December 3, 2010 at 11:08 AM


Hi,

You can use following code for logout:

<?
session_start();
session_destroy();
header("location: index.php");
?>

Thanks



Related Tutorials/Questions & Answers:
How to destory session in PHP
How to destory session in PHP  Hi, I have to write a php page for logout. Please tell me what i should write? Thanks   Hi, You can use following code for logout: <? session_start(); session_destroy(); header
Session in Php
Session in Php   What Is a Session
Advertisements
php session
php session  what is session
What is the default session time in php and how can I change it?
What is the default session time in php and how can I change it?  What is the default session time in php and how can I change
Session management in php - PHP
Session management in php  I am creating a simple program in PHP to manage the session of user. It's basically a simple form that will allow a user to fill & submit the offer form after login. Please Explain me how can i create
Maximum length of Session ( $_SESSION ) in PHP.
Maximum length of Session ( $_SESSION ) in PHP.  sir, i want to know that how much limit of storing data into session in php. i mean can i store full product descriptions into session. Thank u
php maintain session id
php maintain session id   How to maintain session ID for a user in PHP
php session timeout
php session timeout  How to check if the session is out or timeout have occurred in the PHP application
session update in php
session update in php  How to session update in php?   $this->session->set_userdata('name', $fullname
Create Session Variable PHP
Create Session Variable PHP  hi, Write a program which shows the example of how to create session variable in PHP. Please suggest the reference... session Variable in PHP. May be this reference will solve your query. Thanks
php session for login and logout
php session for login and logout  Session management code to create a login and logout session in PHP. Thanks
session cookies expire - PHP
session cookies expire  when do a session cookies expire in PHP
PHP Session
Session: A session variable is used to store some useful data and that data is accessible from every page. In PHP $_SESSION is a pre-defined variable... (before html). Example: <?php session_start(); if(isset($_SESSION
iPhone php session
iPhone php session  Hi, I am developing an application for iPhone. In my application user validated with a php file on server. Now I don't know how... code for session management in iPhone application backed with PHP server code
session management for login logout in php
session management for login logout in php  how to manage session for login and logout in php
php session - Security
php session  My php session value is doesn't get. I checked the php code is correct. when this runs under php4 version. But didn't run under php5... Friend, Please visit the following link: http://roseindia.net/php/php
PHP Session
PHP Session        A PHP session variable is used to store the information about a user... in the URL.   Example 1:   <?php SESSION_start(); if(isset
setting php session variable by ajax
setting php session variable by ajax  Hello folks, i developing a php website where the content of the section load dynamically from database... tried to use AJAX to call another PHP script to set the session variable
How To Turn On the Session Support?
How To Turn On the Session Support?  How To Turn On the Session Support
in php What the code is to be written for Authentication with Session Control
in php What the code is to be written for Authentication with Session Control  in php What the code is to be written for Authentication with Session Control
how to create session for login
how to create session for login  how to create session for login? how to display uploaded resume and images in the profile
session
Session Management in PHP  Handling session in PHP. Can anyone please explain it with the help of an existing example about, how to handle a session while a user is logged in PHP
Session Modification
Session Modification in PHP Session modification can be done through incrementing the loop. As the counting of loop increments, the session be modified. ... of the session register.  Run the counter.  <?php session_start
session
session  create multiple login on one page in php but how to use session
Create session variable.
Create session variable In this example, you will learn how to create session... an Email field and fix submit buttton. Create a session variable code in PHP... email address, the value of the session is set.  <?php session_start
Decoding the session
session. <?php session_start(); $session=$_SESSION["brijesh"...Decoding the Session session_decode() is used for decoding session. It decodes the session from a string. It returns True on success or False on failure
Starting the session.
session_start(); Example: <?php session_start(); echo "your...session_start() session_start function creates a session or resumes the current one based on the  current session id that is being passed via a request
Fatal error: Call to undefined function session_register() in .php file
Fatal error: Call to undefined function session_register() in .php file  I upgraded the PHP and MySQL and in my application following error is coming: Fatal error: Call to undefined function session_register() in ...php file
session_save_path()
session_save_path() session_save_path() command returns the current working directory path.  Syntax session_save_path(); Example: <?php echo session_save_path(); #return the current working directory path ?>  
How to use session in struts 1.3
How to use session in struts 1.3  i want to know how to use session in Struts specially in logIn authentication
Session Register
Session Register For session register, you will have to first create an action form in HTML that calls the php session_register code.   In PHP form... code, we have used server[PHP_SELF] call.  <?php session_start
 

 

 

DMCA.com