note 110211 added to function.is-numeric

From: Date: Mon, 01 Oct 2012 10:44:46 +0000
Subject: note 110211 added to function.is-numeric
Groups: php.notes php.notes 
Request: Send a blank email to php-notes+get-191087@lists.php.net to get a copy of this message
To check if a string has any number in it function str_contains_number($test_string) { $length = strlen($test_string); for($i = 0; $i < $length; $i++) { $current_char = $test_string[$i]; if($current_char >= '0' && $current_char <= '9') { return true; } } return false; } ---- Server IP: 69.147.83.199 Probable Submitter: 164.40.216.42 ---- Manual Page -- http://www.php.net/manual/en/function.is-numeric.php Edit -- https://master.php.net/note/edit/110211 Del: integrated -- https://master.php.net/note/delete/110211/integrated Del: useless -- https://master.php.net/note/delete/110211/useless Del: bad code -- https://master.php.net/note/delete/110211/bad+code Del: spam -- https://master.php.net/note/delete/110211/spam Del: non-english -- https://master.php.net/note/delete/110211/non-english Del: in docs -- https://master.php.net/note/delete/110211/in+docs Del: other reasons-- https://master.php.net/note/delete/110211 Reject -- https://master.php.net/note/reject/110211 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#191087) next »