Doc #60103 [Opn->Csd]: Error on ctype_digit() function manual page

From: Date: Tue, 01 Nov 2011 22:21:03 +0000
Subject: Doc #60103 [Opn->Csd]: Error on ctype_digit() function manual page
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-7377@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=60103&edit=1 ID: 60103 Updated by: salathe@php.net Reported by: ivanhoe011 at gmail dot com Summary: Error on ctype_digit() function manual page -Status: Open +Status: Closed Type: Documentation Problem Package: Documentation problem PHP Version: Irrelevant -Assigned To: +Assigned To: salathe Block user comment: N Private report: N New Comment: This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. I added a note to all of the ctype_*() functions. Previous Comments: ------------------------------------------------------------------------ [2011-11-01 22:17:02] salathe@php.net Automatic comment from SVN on behalf of salathe Revision: http://svn.php.net/viewvc/?view=revision&revision=318662 Log: note for ctype_* and integer input (doc #60103) ------------------------------------------------------------------------ [2011-10-20 13:42:09] ivanhoe011 at gmail dot com Description: ------------ --- From manual page: http://www.php.net/function.ctype-digit --- The above manual page contains a note that states: "This function requires a string to be useful, so for example passing in an integer will always return FALSE." This is not true, as e.g. calling ctype_digit(48) will return TRUE. As explained elsewhere in the manual for all ctype_* functions: "if you pass an integer smaller than 256 it will use the ASCII value of it to see if it fits in the specified range (digits are in 0x30-0x39). If the number is between -128 and -1 inclusive then 256 will be added and the check will be done on that." ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=60103&edit=1

« previous php.doc.bugs (#7377) next »