Re: Insert Record with Photo Uploads



On 29 June, 20:33, newbie198 <singleton.m...@xxxxxxxxx> wrote:
Big Problem I would like the form to be able to write the photo to
database  but inform user if its too large or if they are trying to
upload a different file type other than jpeg or gif. I think the if
and else statement is not correct. Just need extra security.Thank you
for all your help.


The time to check if the file is too large is not after its been
uploaded. And allowing users to pic their own filename is just plain
wrong.

if (mysql_query($sql, $conn/*$uploaded_size<350000*/))

You've commented out the file size check - so if the query fails it
will report that the file is too big.

C.
.



Relevant Pages

  • Help required with converting family tree
    ... a jpeg or gif that I can upload onto a website? ...
    (soc.genealogy.britain)
  • Re: GIF PHP Exploit
    ... How this exploit is related specifically to GIF files? ... You can upload a specially crafted GIF ... image that embeds PHP code. ... Depending on you serve uploaded GIF files, the embedded PHP code may be ...
    (comp.lang.php)
  • Re: GIF PHP Exploit
    ... How this exploit is related specifically to GIF files? ... You can upload a specially crafted GIF ... image that embeds PHP code. ... because the PHP code may be embedded in the image palette space. ...
    (comp.lang.php)
  • Re: VISIO Drawings convert to jpeg or gif
    ... "driller" wrote in message ... >into a jpeg or gif to upload them onto the web. ...
    (microsoft.public.visio.general)
  • Re: FrontPage 2003 GIF Animations
    ... WS_FTP PRO indicates perfect execution of animations at ... >- resaving a .gif in anything but a gif animator program ... FrontPage] ... >| upload and publishing of the gif animations, ...
    (microsoft.public.frontpage.programming)