note 92677 added to function.is-int
| From: | ricierik at gmail dot com | Date: | Mon, 03 Aug 2009 20:05:54 +0000 |
| Subject: | note 92677 added to function.is-int | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-159062@lists.php.net to get a copy of this message | ||
@ Roberto Rama
Your function works great, but only if the input is an unsigned integer number. what if I put in
"-234"?
If someone needs a better way or an extended way of checking integers, I suggest you take a look at
the function that was written by paulo dot koch at g_mail dot com, but corrected by leonix at motd
dot ru.
Or use the function that was written by mark at codedesigner dot nl which also supports signed
integers.
----
Server IP: 209.41.74.194
Probable Submitter: 84.255.242.236
----
Manual Page -- http://www.php.net/manual/en/function.is-int.php
Edit -- https://master.php.net/note/edit/92677
Del: integrated -- https://master.php.net/note/delete/92677/integrated
Del: useless -- https://master.php.net/note/delete/92677/useless
Del: bad code -- https://master.php.net/note/delete/92677/bad+code
Del: spam -- https://master.php.net/note/delete/92677/spam
Del: non-english -- https://master.php.net/note/delete/92677/non-english
Del: in docs -- https://master.php.net/note/delete/92677/in+docs
Del: other reasons-- https://master.php.net/note/delete/92677
Reject -- https://master.php.net/note/reject/92677
Search -- https://master.php.net/manage/user-notes.php