Reply to Re: Testing if an array is empty

Your name:

Reply:


Posted by burgermeister01 on 08/13/07 15:44

On Aug 13, 10:32 am, zzapper <zzap...@gmail.com> wrote:
> Hi,
> Have tried to google this without 100% satisfaction.
>
> A function reads a mysql record into an array and returns it, if it
> doesnt exist it returns '' or FALSE.
>
> What ways do I have to test that my returned array is not empty
>
> --
> zzapper
> Best of VimTipshttp://www.vim.org/tips/tip.php?tip_id=305

The two immediate methods that pop into my head are as follows:

1.
if(count($array) == 0)

2.
if(empty($array))

There could be more, but these should do the job ok.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация