On 17 June 2009 14:30, PJ advised:

> For the moment, I am trying to resolve the problem of
> extracting a value
> from a string returned by a query. I thought that in_array() would do
> it, but the tests I have run on it are 100% negative. The only thing I
> have not used in the tests is third parameter bool $strict which only
> affects case-sensitivity if the $needle is a string.

$strict has nothing whatsoever at all in any way to do with case
sensitivity -- $strict controls whether the values are compared using
equality (==) or identity (===) tests. As is stated quite clearly on the
manual page, in_array() is always case-sensitive. 

>  This leads me to
> believe that in_array() is either inappropriately defined in
> the manual
> and not effective on associative arrays

Complete rubbish -- the in_array() manual page is excellent and totally
accurate, complete with 3 working examples.



Mike Ford,  Electronic Information Developer,
C507, Leeds Metropolitan University, Civic Quarter Campus, 
Woodhouse Lane, LEEDS,  LS1 3HE,  United Kingdom
Email: m.f...@leedsmet.ac.uk
Tel: +44 113 812 4730

To view the terms under which this email is distributed, please go to 

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to