how to check if a $_FILE is set in php?

前端 未结 5 1802
情书的邮戳
情书的邮戳 2021-01-04 12:01

I\'ve created a form with 3

I see that I get an array with array(name=>\"\").

So I check if (

5条回答
  •  借酒劲吻你
    2021-01-04 12:14

    You can try this:

    if($_FILES['myfilename']['size'] > 0 ) {
    
    }
    else{
           echo 'File is not uploaded . . .';
    }
    

提交回复
热议问题