Share on Google+Share on Google+

Session Modification

In this example you will learn how to do the session modification in PHP.

Session Modification in PHP

Session modification can be done through incrementing the loop. As the counting of loop increments, the session be modified. 

First of all, begin the session with session_start(),  set the input of the session register. 

Run the counter. 


if ($count==1) {
$mess= "one time!";
} else {
$mess="accessed this page $count times.";
<?php echo $mess; ?>

The Output:

The output will be modified session.


Posted on: July 31, 2009 If you enjoyed this post then why not add us on Google+? Add us to your Circles

Share this Tutorial Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.


Advertisement null