I have created a button called "Generate" , when click event is performed it should start a timer after reaching 60 sec it should perform an if statement. I tried the following code but its not working.
if(isset($_POST['generate']))
{
$timer = time();
if($timer = $timer+5)
{
$query = mysql_query("UPDATE user_login SET password='' WHERE username = 'ajai sandy'") ;
$qry_run = mysql_query($query);
}
In the above code I have used the system time , I could use both the system time or a timer to complete this action.