Please help,
I'm trying to submit a .jpg image via a html form and showing it with the
following piece of code
<?php
if ($submit) {
header("Content-type: $form_data_type");
$data = fread(fopen($form_data, "r"), filesize($form_data));
echo $data;
}
else {
?>
<form method="post" action="<?php echo $PHP_SELF ?>"
enctype="multipart/form-data">
<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="1000000">
<br>File to show:<br>
<input type="file" name="form_data" size="40">
<p><input type="submit" name="submit" value="submit">
</form>
<?php
}
?>
but I only get the binary contents of the .jpg file. What's wrong?
My hostmaster has an infobar running at the top of my page [check
www.oss-fodbold.dk to see what I mean]. Is this the problem?
Thanks in advance
Simon
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]