Re: Variable Variables & File Attributes

From: Date: Wed, 02 Aug 2000 23:45:03 +0000
Subject: Re: Variable Variables & File Attributes
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-9848@lists.php.net to get a copy of this message
My bad. When I typed the code into the email message, I must've been thinking ahead of myself and typed $file_size when I meant $file_type because I will also need to use this to check the file size. Just to be sure I double checked again and the code on the server does in fact say: if ($file_type == "image/jpeg") Also if put the following lines into the code: echo ("File Size: $file_size") echo ("File Type: $file_type") all that is sent to output is: File Size: File Type: I am sorry for any inconvieiences my typo may have caused and hope that you would be willing to take another look at my problem. To confirm that the code is correct (so to speak) I copied the files to the following locations so you may view them if desired. http://www.rfcomsites.com/updaterecord.html http://www.rfcomsites.com/copyimages.html Thanks Chad At 04:02 PM 8/2/00, Rasmus Lerdorf wrote:
if ($file_size == "image/jpeg"){ //evaluates false even if it is a jpeg That's because $file_size holds the size of the file and not the file type. -Rasmus


« previous php.general (#9848) next »