Re: A general UL script

From: Date: Sat, 28 Oct 2006 21:33:30 +0000
Subject: Re: A general UL script
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-243801@lists.php.net to get a copy of this message
Børge Holen wrote:
When I use a normal single file upload form; both of these statements will continue wether my form is empty or not, why? if(!empty($_FILES)){ do som checking if its a jpg. if not exit; if(isset($_FILES)){
because it IS set and NOT empty. $_FILES['file_upload_field'] is set, it's got no data, but it IS set. $_FILES is set because $_FILES['file_upload_field'] exists. Submitting a blank form sends all "variables" though without actual (non-default) content. - tul

« previous php.general (#243801) next »