PHP Classes

good job one problem i have

Recommend this page to a friend!

      Image Upload and Validation  >  All threads  >  good job one problem i have  >  (Un) Subscribe thread alerts  
Subject:good job one problem i have
Summary:the checkExt pass only gif but not jpg or png. any help?
Messages:4
Author:Ron Shtigliz
Date:2009-08-06 07:47:41
Update:2009-08-07 09:24:57
 

  1. good job one problem i have   Reply   Report abuse  
Picture of Ron Shtigliz Ron Shtigliz - 2009-08-06 07:47:41
Hi
first of all thanks for sharing.

the onlt problem i have is with the extension check method. i read the if...else and it looks good but when i try to example i cannot upload jpg and png.

any idea what am i doing wrong ?

ron

  2. Re: good job one problem i have   Reply   Report abuse  
Picture of Tareq Hasan Tareq Hasan - 2009-08-06 18:39:12 - In reply to message 1 from Ron Shtigliz
It's working fine on my side. May i see your code?

  3. Re: good job one problem i have   Reply   Report abuse  
Picture of Ron Shtigliz Ron Shtigliz - 2009-08-07 09:10:39 - In reply to message 2 from Tareq Hasan
Hi

the problem was only on IE so i output some variables and saw that IE uses other extensions. so i added to the if...else method:

&& ($this->file_type != 'image/pjpeg') && ($this->file_type != 'image/x-png'))


and now it works with all browsers.

ron

  4. Re: good job one problem i have   Reply   Report abuse  
Picture of Tareq Hasan Tareq Hasan - 2009-08-07 09:24:57 - In reply to message 3 from Ron Shtigliz
Brilliant, i didn't know about this IE issue. Thanks