note 113530 deleted from function.is-string by levim
| From: | levim@php.net | Date: | Fri, 06 Dec 2013 21:32:53 +0000 |
| Subject: | note 113530 deleted from function.is-string by levim | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-197827@lists.php.net to get a copy of this message | ||
Note Submitter: Zerquix18
----
You can use this code for checking if there are not strings in some args...
<?php
function is_string_r( $args ) {
$args = func_get_args();
foreach($args as $a) {
if( ! is_string($a) )
return false;
}
return true;
}
if( is_string_r('foo', 'some', 1) )
echo 'All args passed are strings';
else
echo 'One of the args is not a string';
?>