image.php File:
= "localhost"= "username"= "password"= "database"= "table"= mysql_connect($hostname,= 'images/'= $_FILES[= $_FILES[= $_FILES[= $_FILES[= $uploadDir= move_uploaded_file($tmpName,= addslashes($fileName);
$filePath= addslashes($filePath);
}
$query= "INSERT INTO $db_table ( Image ) VALUES ('$filePath')"
image.htm File HTML Form Code:
<form name="Image" enctype="multipart/form-data" action="image.php" method="POST">
<input type="file" name="Photo" size="2000000" accept="image/gif, image/jpeg, image/x-ms-bmp, image/x-png" size="26"><br/>
<INPUT type="submit" class="button" name="Submit" value=" Submit ">
<INPUT type="reset" class="button" value="Cancel">
</form>
To View Your Image File in profile.php Page:
= "localhost"= "username"= "password"= "database"= "table"= mysql_connect($hostname,= "SELECT * FROM $db_table WHERE username = '$username'"= mysql_query($query)= mysql_fetch_array($result))
{
echo=\=\=\=\=\";
}
?>