session.counter.php 142 B

1234567
  1. <?php
  2. session_start();
  3. if (!isset($_SESSION['counter'])){
  4. $_SESSION['counter'] = 0;
  5. }
  6. $_SESSION['counter'] ++;
  7. echo $_SESSION['counter'];