Why session is empty when I try to track upload?


<?php

session_start(); 

 if($_SERVER['REQUEST_METHOD']=='POST'){ 

   print_r($_SESSION);  

 }

?>

<!DOCTYPE html>

<html>

    <head></head>

    <body>

     <div class="min">

     <form action="<?php echo $_SERVER['PHP_SELF']?>" method="POST" enctype="multipart/form-data">

 <input type="hidden" name="<?php echo ini_get("session.upload_progress.name"); ?>" value="123" />

 <input type="file" name="file1" />

 <input type="submit" />

</form>

     </div>

     <script src='dani.js'></script>

    </body>

</html>

Above is my code and I try to upload file but I also want to track it’s progress. I am using upload progress but it seems not working because after posting form, I don’t get any data in session. Can anybody help me with this problem? any help will be appreciated.