开发者网络 动网主机 支持论坛 邮局 帮助
当前位置:网络学院PHP技术入门教程 → PHP4.04 新增加了专用的字符函数 Ctype
PHP4.04 新增加了专用的字符函数 Ctype
日期:2001年4月11日 作者: 人气:     [ ]
Character type functions
These functions check whether a character or string falls into a certain character class according to the i current locale.
这些函数根据当前现场的 i 检查一个字符或字符串是否在一个字符类里面!

When called with an integer argument these functions behave exactly like their C counterparts.
当使用整数参数调用时,这些函数和 C 里面的函数完全匹配。

When called with a string argument they will check every character in the string and will only return true if every character in the string matches the requested criteria.
当使用字符串参数,将检查字符串里面的每一个字符,如果字符串里面的每个字符都等同于请求标准时返回 true.

Passing anything else but a string or integer will return false immediately.
传送非字符串或整数的参数将立即返回 false


Warning
警告:

These functions are new as of PHP 4.0.4 and might change their name in the near future. Suggestions are to change them to ctype_issomething() instead of ctype_somthing() or even to make them part of ext/standard and use their original C-names, although this would possibly lead to further confusion regarding the isset() vs. is_sometype() problem.

这些函数是 php4.04 新增加的。可能在近期改变。建议包括更改 ctype_issomething() 代替 ctype_somthing(),甚至让他们成为扩展/标准的一部分,和使用他们的原始 C_名字。尽管可能导致将来 isset() 对 is_sometype() 的混乱。

(出处:www.php.net)

相关文章:
 
·全正则的检测IP是否合法的函数
·随机生成文件名的函数
·一段在asp中加密与解密对应的函数
·用自定义函数获取汉字的首字母
·一个测试数据库连接的函数
·按下回车键指向下一个位置的一个函数
·一个不错的随机函数
·一套加解密字符串的函数
·一段加密函数(base64)
·一段加密函数
相关软件:
 
说明:本站部分内容收集于网络,如有侵犯您的权益请来信告知,我们会第一时间进行处理,谢谢
 → 特别推荐
 → 热点TOP10

关于本站 | 诚聘英才 | 业务合作 | 联系我们 | 广告合作 | 收藏本站

海口动网先锋网络科技有限公司版权所有
Copyright ? 2000 - 2003 AspSky.Net
中华人民共和国电信与信息服务业务经营许可证编号 琼 ICP 020077