upload.php-
<?php
$target_file ="uploads/". basename($_FILES["fileToUpload"]["name"]);
if(move_uploaded_file($_FILES["fileToUpload"]["tmp_name"], $target_file))
{
echo "upload";
}
?>
1.html-
<html>
<body>
<form action="upload.php" method="post" enctype="multipart/form-data">
Select file to upload:
<input type="file" name="fileToUpload" >
<input type="submit" value="Upload Image" name="submit">
</form>
</body>
</html>