PHP实例:常用的数值判别函数
发布时间:2023-10-25 13:34:25 所属栏目:PHP教程 来源:
导读:以下为引用的内容:
<HTML>
<HEAD>
<TITLE>常用的数值判断函数</TITLE>
</HEAD>
<BODY>
<?
//判断数组
$colors = array("red", "blue", "green");
if(is_array($colors))
{
print("colors is an array"
<HTML>
<HEAD>
<TITLE>常用的数值判断函数</TITLE>
</HEAD>
<BODY>
<?
//判断数组
$colors = array("red", "blue", "green");
if(is_array($colors))
{
print("colors is an array"
以下为引用的内容: <HTML> <HEAD> <TITLE>常用的数值判断函数</TITLE> </HEAD> <BODY> <? //判断数组 $colors = array("red", "blue", "green"); if(is_array($colors)) { print("colors is an array"."<br>"); } //双精度数判断 $Temperature = 15.23; if(is_double($Temperature)) { print("Temperature is a double"."<br>"); } //整数判断 $PageCount = 2234; if(is_integer($PageCount)) { print("$PageCount is an integer"."<br>"); } //对象判断 class widget { var $name; var $length; } $thing = new widget; if(is_object($thing)) { print("thing is an object"."<br>"); } //字符判断 $Greeting = "Hello"; if(is_string($Greeting)) { print("Greeting is a string"."<br>"); } ?> </BODY> </HTML> (编辑:汽车网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
推荐文章
站长推荐