note 29250 deleted from function.strrpos by tix

From: Date: Fri, 07 Feb 2003 12:59:46 +0000
Subject: note 29250 deleted from function.strrpos by tix
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-43555@lists.php.net to get a copy of this message
For beginners: Note: <?php $mystring = "asasdb"; $pos = strrpos($mystring, "b"); if ($pos == true){ echo $pos;} ?> would give you $pos = 5 and not pos$ = 6 as you would expect. reason = it start's count on 0, and not 1.

« previous php.notes (#43555) next »