note 19195 added to function.preg-match

From: Date: Tue, 19 Feb 2002 13:43:57 +0000
Subject: note 19195 added to function.preg-match
Groups: php.notes 
Request: Send a blank email to php-notes+get-26793@lists.php.net to get a copy of this message
preg_match() returns an integer type rather than a boolean. Is this a bug of sorts given that it only returns true/false? You have to cast it to boolean if you want to use the result in a overloaded (by type) function, for example. -- http://www.php.net/manual/en/function.preg-match.php http://master.php.net/manage/user-notes.php?action=edit+19195 http://master.php.net/manage/user-notes.php?action=delete+19195 http://master.php.net/manage/user-notes.php?action=reject+19195

« previous php.notes (#26793) next »