Reply to Re: finding data in an array

Your name:

Reply:


Posted by Janwillem Borleffs on 01/15/06 01:12

windandwaves wrote:
> What is the most efficient way to do this? Is there a function that I
> can use? Something like
>

AFAIK, there isn't an out-of-the-box function for this, so all I can offer
you is an alternative to what you have posted:

function datafieldcheck($ma, $fld) {
$current = current($ma);
if (isset($current[$fld])) {
$v = $current[$fld];
while (false !== ($current = next($ma))) {
if (!isset($current[$fld]) || strcmp($v, $current[$fld])) {
return false;
}
}
return true;
}
return false;
}


JW

[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

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