strtok buggy ?

From: Date: Wed, 28 Jun 2000 12:15:38 +0000
Subject: strtok buggy ?
Groups: php.dev 
Request: Send a blank email to php-dev+get-22613@lists.php.net to get a copy of this message
Hi, It seem that strtok trouble with the 0 string. Try this little script : $str = "ta-mere-en-0-short"; $tok = strtok ($str,"-"); while ($tok) { echo "->$tok<BR>\n"; $tok = strtok("-"); } The result : -> ta -> mere -> en When you try with the string $str = "ta-mere-en-00-short", it work. Bye, Chesneau Serge.

« previous php.dev (#22613) next »