PHP之string
string
addcslashes()
- Quote string with slashes in a C style
- 以 C 语言风格使用反斜线转义字符串中的字符
addslashes()
- Quote string with slashes
- 使用反斜线引用字符串
bin2hex()
- Convert binary data into hexadecimal representation
- 函数把包含数据的二进制字符串转换为十六进制值
chop()
- Alias of rtrim
- rtrim 的别名
chr()
- Return a specific character
- 返回指定的字符
chunk_split()
- Split a string into smaller chunks
- 将字符串分割成小块
convert_cyr_string()
- Convert from one Cyrillic character set to another
- 将字符由一种 Cyrillic 字符转换成另一种
convert_uudecode()
- Decode a uuencoded string
- 解码一个 uuencode 编码的字符串
convert_uuencode()
- Uuencode a string
- 使用 uuencode 编码一个字符串
count_chars()
- Return information about characters used in a string
- 返回字符串所用字符的信息
crc32()
- Calculates the crc32 polynomial of a string
- 计算一个字符串的 crc32 多项式
crypt()
- One-way string hashing
- 单向字符串散列
echo()
- Output one or more strings
- 输出一个或多个字符串
explode()
- Split a string by string
- 使用一个字符串分割另一个字符串
fprintf()
- Write a formatted string to a stream
- 将格式化后的字符串写入到流
get_html_translation_table()
- Returns the translation table used by htmlspecialchars and htmlentities
- 返回使用 htmlspecialchars 和 htmlentities 后的转换表
hebrev()
- Convert logical Hebrew text to visual text
- 将逻辑顺序希伯来文(logical-Hebrew)转换为视觉顺序希伯来文(visual-Hebrew)
hebrevc()
- Convert logical Hebrew text to visual text with newline conversion
- 将逻辑顺序希伯来文(logical-Hebrew)转换为视觉顺序希伯来文(visual-Hebrew),并且转换换行符
hex2bin()
- Decodes a hexadecimally encoded binary string
- 转换十六进制字符串为二进制字符串
html_entity_decode()
- Convert all HTML entities to their applicable characters
htmlentities()
- Convert all applicable characters to HTML entities
- 将字符转换为 HTML 转义字符
htmlspecialchars_decode()
- Convert special HTML entities back to characters
- 将特殊的 HTML 实体转换回普通字符
htmlspecialchars()
- Convert special characters to HTML entities
- 将特殊字符转换为 HTML 实体
implode()
- Join array elements with a string
- 将一个一维数组的值转化为字符串
join()
- Alias of implode
- 别名 implode
lcfirst()
- Make a string's first character lowercase
- 使一个字符串的第一个字符小写
levenshtein()
- Calculate Levenshtein distance between two strings
- 计算两个字符串之间的编辑距离
localeconv()
- Get numeric formatting information
ltrim()
- Strip whitespace (or other characters) from the beginning of a string
- 删除字符串开头的空白字符(或其他字符)
md5_file()
- Calculates the md5 hash of a given file
- 计算指定文件的 MD5 散列值
md5()
- Calculate the md5 hash of a string
- 计算字符串的 MD5 散列值
metaphone()
- Calculate the metaphone key of a string
money_format()
- Formats a number as a currency string
- 将数字格式化成货币字符串
nl_langinfo()
- Query language and locale information
nl2br()
- Query language and locale information
- 在字符串所有新行之前插入 HTML 换行标记
number_format()
- Format a number with grouped thousands
- 以千位分隔符方式格式化一个数字
ord()
- Return ASCII value of character
- 返回字符的 ASCII 码值
parse_str()
- Parses the string into variables
- 将字符串解析成多个变量
print()
- Output a string
- 输出字符串
printf()
- Output a formatted string
- 输出格式化字符串
quoted_printable_decode()
- Convert a quoted-printable string to an 8 bit string
- 将 quoted-printable 字符串转换为 8-bit 字符串
quoted_printable_encode()
- Convert a 8 bit string to a quoted-printable string
- 将 8-bit 字符串转换成 quoted-printable 字符串
quotemeta()
- Quote meta characters
- 转义元字符集
rtrim()
- Strip whitespace (or other characters) from the end of a string
- 删除字符串末端的空白字符(或者其他字符)
setlocale()
- Set locale information
- 设置地区信息
sha1_file()
- Calculate the sha1 hash of a file
- 计算文件的 sha1 散列值
sha1()
- Calculate the sha1 hash of a string
- 计算字符串的 sha1 散列值
similar_text()
- Calculate the similarity between two strings
- 计算两个字符串的相似度
soundex()
- Calculate the soundex key of a string
sprintf()
- Return a formatted string
sscanf()
- Parses input from a string according to a format
- 根据指定格式解析输入的字符
str_getcsv()
- Parse a CSV string into an array
- 解析 CSV 字符串为一个数组
str_ireplace()
- Case-insensitive version of str_replace
- str_replace 的忽略大小写版本
str_pad()
- Pad a string to a certain length with another string
- 使用另一个字符串填充字符串为指定长度
str_repeat()
- Repeat a string
- 重复一个字符串
str_replace()
- Replace all occurrences of the search string with the replacement string
- 子字符串替换
str_rot13()
- Perform the rot13 transform on a string
- 对字符串执行 ROT13 转换
str_shuffle()
- Randomly shuffles a string
- 随机打乱一个字符串
str_split()
- Convert a string to an array
- 将字符串转换为数组
str_word_count()
- Return information about words used in a string
- 返回字符串中单词的使用情况
strcasecmp()
- Binary safe case-insensitive string comparison
- 二进制安全比较字符串(不区分大小写)
strchr()
- Alias of strstr
- 别名 strstr
strcmp()
- Binary safe string comparison
- 二进制安全字符串比较
strcoll()
- Locale based string comparison
- 基于区域设置的字符串比较
strcspn()
- Find length of initial segment not matching mask
- 获取不匹配遮罩的起始子字符串的长度
strip_tags()
- Strip HTML and PHP tags from a string
- 从字符串中去除 HTML 和 PHP 标记
stripcslashes()
- Un-quote string quoted with addcslashesshes 转义的字符串
- 反引用一个使用 addcsla
stripos()
- Find the position of the first occurrence of a case-insensitive substring in a string
- 查找字符串首次出现的位置(不区分大小写)
stripslashes()
- Un-quotes a quoted string
- 反引用一个引用字符串
stristr()
- Case-insensitive strstr
- strstr 函数的忽略大小写版本
strlen()
- Get string length
- 获取字符串长度
strnatcasecmp()
- Case insensitive string comparisons using a "natural order" algorithm
- 使用“自然顺序”算法比较字符串(不区分大小写)
strnatcmp()
- String comparisons using a "natural order" algorithm
- 使用自然排序算法比较字符串
strncasecmp()
- Binary safe case-insensitive string comparison of the first n characters
- 二进制安全比较字符串开头的若干个字符(不区分大小写)
strncmp()
- Binary safe string comparison of the first n characters
- 二进制安全比较字符串开头的若干个字符
strpbrk()
- Search a string for any of a set of characters
- 在字符串中查找一组字符的任何一个字符
strpos()
- Find the position of the first occurrence of a substring in a string
- 查找字符串首次出现的位置
strrchr()
- Find the last occurrence of a character in a string
- 查找指定字符在字符串中的最后一次出现
strrev()
- Reverse a string
- 反转字符串
strripos()
- Find the position of the last occurrence of a case-insensitive substring in a string
- 计算指定字符串在目标字符串中最后一次出现的位置(不区分大小写)
strrpos()
- Find the position of the last occurrence of a substring in a string
- 计算指定字符串在目标字符串中最后一次出现的位置
strspn()
- Finds the length of the initial segment of a string consisting entirely of characters contained within a given mask
- 计算字符串中全部字符都存在于指定字符集合中的第一段子串的长度。
strstr()
- Find the first occurrence of a string
- 查找字符串的首次出现
strtok()
- Tokenize string
- 标记分割字符串
strtolower()
- Make a string lowercase
- 将字符串转化为小写
strtoupper()
- Make a string uppercase
- 将字符串转化为大写
strtr()
- Translate characters or replace substrings
- 转换指定字符
substr_compare()
- Binary safe comparison of two strings from an offset, up to length characters
- 二进制安全比较字符串(从偏移位置比较指定长度)
substr_count()
- Count the number of substring occurrences
- 计算字串出现的次数
substr_replace()
- Replace text within a portion of a string
- 替换字符串的子串
substr()
- Return part of a string
- 返回字符串的子串
trim()
- Strip whitespace (or other characters) from the beginning and end of a string
- 去除字符串首尾处的空白字符(或者其他字符)
ucfirst()
- Make a string's first character uppercase
- 将字符串的首字母转换为大写
ucwords()
- Uppercase the first character of each word in a string
- 将字符串中每个单词的首字母转换为大写
vfprintf()
- Write a formatted string to a stream
- 将格式化字符串写入流
vprintf()
- Output a formatted string
- 输出格式化字符串
vsprintf()
- Return a formatted string
- 返回格式化字符串
wordwrap()
- Wraps a string to a given number of characters
- 打断字符串为指定数量的字串
CRYPT_SALT_LENGTH integer
CRYPT_STD_DES integer
CRYPT_EXT_DES integer
CRYPT_MD5 integer
CRYPT_BLOWFISH integer
HTML_SPECIALCHARS (integer)
HTML_ENTITIES (integer)
ENT_COMPAT (integer)
ENT_QUOTES (integer)
ENT_NOQUOTES (integer)
ENT_IGNORE (integer)
ENT_SUBSTITUTE (integer)
ENT_DISALLOWED (integer)
ENT_HTML401 (integer)
ENT_XML1 (integer)
ENT_XHTML (integer)
ENT_HTML5 (integer)
CHAR_MAX (integer)
LC_CTYPE (integer)
LC_NUMERIC (integer)
LC_TIME (integer)
LC_COLLATE (integer)
LC_MONETARY (integer)
LC_ALL (integer)
LC_MESSAGES (integer)
STR_PAD_LEFT (integer)
STR_PAD_RIGHT (integer)
STR_PAD_BOTH (integer)
PHP之string的更多相关文章
- 透过WinDBG的视角看String
摘要 : 最近在博客园里面看到有人在讨论 C# String的一些特性. 大部分情况下是从CODING的角度来讨论String. 本人觉得非常好奇, 在运行时态, String是如何与这些特性联系上的 ...
- JavaScript String对象
本编主要介绍String 字符串对象. 目录 1. 介绍:阐述 String 对象的说明以及定义方式. 2. 实例属性:介绍 String 对象的实例属性: length. 3. 实例方法:介绍 St ...
- ElasticSearch 5学习(9)——映射和分析(string类型废弃)
在ElasticSearch中,存入文档的内容类似于传统数据每个字段一样,都会有一个指定的属性,为了能够把日期字段处理成日期,把数字字段处理成数字,把字符串字段处理成字符串值,Elasticsearc ...
- [C#] string 与 String,大 S 与小 S 之间没有什么不可言说的秘密
string 与 String,大 S 与小 S 之间没有什么不可言说的秘密 目录 小写 string 与大写 String 声明与初始化 string string 的不可变性 正则 string ...
- js报错: Uncaught RangeError: Invalid string length
在ajax请求后得到的json数据,遍历的时候chrome控制台报这个错误:Uncaught RangeError: Invalid string length,在stackoverflow查找答案时 ...
- c# 字符串连接使用“+”和string.format格式化两种方式
参考文章:http://www.liangshunet.com/ca/201303/218815742.htm 字符串之间的连接常用的两种是:“+”连接.string.format格式化连接.Stri ...
- 【手记】注意BinaryWriter写string的小坑——会在string前加上长度前缀length-prefixed
之前以为BinaryWriter写string会严格按构造时指定的编码(不指定则是无BOM的UTF8)写入string的二进制,如下面的代码: //将字符串"a"写入流,再拿到流的 ...
- JavaScript中String对象的方法介绍
1.字符方法 1.1 charAt() 方法,返回字符串中指定位置的字符. var question = "Do you like JavaScript?"; alert(ques ...
- 在多线程编程中lock(string){...}隐藏的机关
常见误用场景:在订单支付环节中,为了防止用户不小心多次点击支付按钮而导致的订单重复支付问题,我们用 lock(订单号) 来保证对该订单的操作同时只允许一个线程执行. 这样的想法很好,至少比 lock( ...
- BCL中String.Join的实现
在开发中,有时候会遇到需要把一个List对象中的某个字段用一个分隔符拼成一个字符串的情况.比如在SQL语句的in条件中,我们通常需要把List<int>这样的对象转换为“1,2,3”这样的 ...
随机推荐
- 用TextWriterTraceListener实现log文件记录 (转载)
log4net之类3方组件确实很方便,但是想写个小小的demo之类的程序,有点用不起啊. 微软自带的TraceListener要实现一个简易的日志帮助类还是很简单的,直接上代码,自己备用,也希望对同样 ...
- Asp.NetCore Razor 模式 Web 应用
Razor 页面是 ASP.NET Core MVC 的一个新功能,它可以使基于页面的编码方式更简单高效. Razor 页面是 ASP.NET Core 2.0 中的一个新选择,它是基于页面的编程模型 ...
- Ubuntu下Jenkins(docker)配置Docker远程启动
背景: 在做用Jenkins构建docker的操作,需要用Jenkins调用docker命令,需要先安装docker-build-step插件,然后开启docker远程访问. 默认情况下,Docker ...
- 好看的table样式
收藏个好看的table样式 <style type="text/css">table.gridtable { font-family: verdana,arial,sa ...
- C# 使用dynamic类型来访问JObject对象
dynamic是C#里面的动态类型,可在未知类型的情况访问对应的属性,非常灵活和方便. 使用Json.Net可以把一个Json字符串转换成一个JObject对象,如果有已知强类型,如果有已知对应的强类 ...
- EF6 使用SQLite Code First
SQLite是一款轻型关系型数据库,做一个小网站,用来替代sql server或者access数据库应该会是一个不错的选择. ASP.NET Entity Framework 6是微软平台的著名ORM ...
- AngularJS入门讲解3:$http服务和路由讲解
上一课的例子中,我们的模型数据是硬编码的,也就是说,我们的数据不是从服务器请求回来的. 这里,我们先讲解,如何从服务器获取数据: function PhoneListCtrl($scope, $htt ...
- SQL查询表结构的语句
SELECT tableName=CASE WHEN a.colorder=1 THEN d.name ELSE '' END ,表说明 =CASE WHEN a.colorder=1 THEN IS ...
- css效果小计
在工作学习中总能发现一些新鲜的页面效果可以用不同的css完成,在这里将遇到的一些css做下记录,以便日后翻阅,如果其中的写法不对,或者有更优写法欢迎留言,不胜感激 1.关于用一个div做出双边框(由于 ...
- C#-集合及特殊集合——★★哈希表集合★★
集合的基本信息: System.Collections命名空间包含接口和类,这些接口和类定义各种对象(如列表.队列.位组数.哈希表和字典)的集合. System.Collections.Generic ...