The value of valid is coming from another page after redirection.In the address bar the value of valid=%273%27. The value is echoing as '3', but still the if statement is evaluating to false.In the database table i have declared the type for variable valid as INT. I have tried changing the type for variable valid into TINYINT and ENUM and VARCHAR also,but to no use.
<?php
$output="";
if($_GET['valid']==3)
{
$output.="<br/><br/><br/>
<h2>You are just one step behind completing your Profile.Please Upload Your Photo Here:</h2>
<br/><br/><br/>";
$output.="<form action=\"loadStudent.php\" method=\"post\" enctype=\"multipart/form-data\">";
$output.="<table>";
$output.="<tr>";
$output.="<td align=\"right\"><font size=\"2\" face=\"Arial\"><strong>Picture</strong></font></td>";
$output.="<td align=\"center\">:</td>";
$output.="<td>";
$output.="<input type=\"hidden\" name=\"MAX_FILE_SIZE\" value=\"10485760\">";
$output.="<input type=\"file\" name=\"image\" id=\"file\" size=\"255\"> <font size=\"5\" face=\"Arial\"> Maxsize 1MB</font>";
$output.="</td>";
$output.="</tr>";
$output.="<tr><td>  </td></tr>
<tr><td>  </td><td colspan=\"2\"><input type=\"submit\" name=\"submit\" value=\"Submit\"></td>";
$output.=" </tr>";
$output.="</table>";
$output.="</form>";
echo $userId;
echo $output;
}//if($valid==3)
echo $_GET['valid'];
?>