I was trying to make this secret area were my friends could only access too so that they could could upload things. What is wrong with my code, please help.
This is the HTML page
<!--body begin-->
<table width="530" bgcolor="#227293" border="3" cellpadding="4">
<tr>
<td>
<font color="white">
<h3>Friend Corner(Restricted)</h3>
<p>Hi this part of the site is a place for my personal friends
to get access to a special treat. I'm proud to have as many as visitors as possible to my site
so please dn't be offended I just allow certain people in this area.<br>
<form method="get" action="friend.php">
Username: <input type="text" name="user"><br>
Password: <input type="password" name="pass"><br>
<input type="submit" value="submit">
</form>
this is my php code
<?php
if( $_GET['user'] = "user" and $_GET['pass'] = "password" ) {
print("<form method="post" action="friend.php">Upload file: <input type="file" name="userfile"><br><input type="submit" value="send file"></form>");
$filename = $_FILES['userfile']['name'];
$filesize = $_FILES['userfile']['size'];
print "Recieved $filename - it's size is $filesize";
} else {
print "You didn't put the right info!"
}
?>