Page 2 of 2

Re: Array foreach loop proplem

Posted: Thu Jun 03, 2010 11:35 am
by tito85
You are great! It seems that date issue is solved too!

However why if no image is uploaded the "Only .jpg images are allowed to be uploaded" is being displayed?

Re: Array foreach loop proplem

Posted: Thu Jun 03, 2010 12:24 pm
by AbraCadaver
tito85 wrote:You are great! It seems that date issue is solved too!

However why if no image is uploaded the "Only .jpg images are allowed to be uploaded" is being displayed?

Code: Select all

if ($image) {
should be:

Code: Select all

if (!empty($image)) {

Re: Array foreach loop proplem

Posted: Thu Jun 03, 2010 12:44 pm
by tito85
I already tried that but still same problem happens

Re: Array foreach loop proplem

Posted: Thu Jun 03, 2010 12:51 pm
by AbraCadaver
Sorry, I didn't look at the actual form:

Code: Select all

if (!empty($image['name'])) {

Re: Array foreach loop proplem

Posted: Thu Jun 03, 2010 1:52 pm
by tito85
Thank a lot for all your help and time my friend!!!

You are great!