Switch to full style
:read: Start PHP with us. Includes topics to help you in php
Post a reply

Modify Session Variables

Sun Oct 26, 2008 8:33 pm

Code:

<?php
  session_start
();
  
session_register('access_count');
  
$access_count++;
  
  if (
$access_count==1) {
    echo 
"the first time!";
  } else {
    
$message="accessed this page $access_count times.";
  }
?>
  <html>
  <head>
  <title>Access Count</title>
  </head>
  <body>
  <?php  echo "$message"?>
  </body>
  </html>




Post a reply
  Related Posts  to : Modify Session Variables
 PHP session variables     -  
 PHP session variables problem in Firefox     -  
 Local variables vs Instance variables     -  
 session in jsp     -  
 PHP Variables     -  
 Scope Variables in php     -  
 php login with session     -  
 Apache Variables in php     -  
 Variables Are Assigned by Value     -  
 EJB session bean     -  

Topic Tags

PHP Variables, PHP Sessions