php - How can I go back to the previous page (using the browsers back button), without throwing any error "Confirm Form Resubmission" -


how can go previous page without throwing error confirm form resubmission, i've searched, followed patters such storing posted data in session variable in page main page , redirect session variable navigating page. doesn't work :(

this code:

index.php

  <form method="post" action="value.php">     <div id="bar">     <div id="banner">                    <img id="img1" src='1.png' height='40' width='200'>                  &nbsp &nbsp &nbsp &nbsp  &nbsp &nbsp  &nbsp &nbsp  &nbsp &nbsp  &nbsp &nbsp                     <div id ="login">                  log-in &nbsp &nbsp &nbsp                  username: &nbsp <input type = "text" name = "username" size = "20" maxlength = "40"> &nbsp &nbsp                 password: &nbsp <input type = "password" name = "pass" size = "20" maxlength = "30"> &nbsp &nbsp                 <input type = "submit" name = "btnlog" value = "login" id="btn">                  <div id="flip">                 <p> forgot password? </p> &nbsp                  </div>                  </div>     </div>      </form> 

value.php

<?php   session_start();      $te = $_post['username'];     $te1 = $_post['pass'];     $_session['username'] = $te;     $_session['password'] = $te1;     $log = $_post['btnlog'];     $_session['login'] = $log;     header("location: main.php");  ?> 

main.php

session_start();     $use = $_session['username'];         $pas = $_session['password'];            $getinfo = "select user_name,pass_word,id users user_name = '".$use."' , pass_word = '".$pas."'";         $query = mysql_query($getinfo);         $getsomerows = mysql_fetch_array($query);         $_session['ids'] = $getsomerows['id']; 


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

visual studio 2010 - Connect to informix database windows form application -

android - Associate same looper with different threads -