01 2021 档案

摘要:is_finite () 判断是否为有限值 bool is_finite ( float $val ) 说明: 检查 val 是否是是本机平台上浮点数所允许范围中的一个合法的有限值。参数: val 要检查的值 返回值: 如果 val 是本机平台上 PHP 浮点数所允许范围中的一个合法的有限值,则返回 阅读全文
posted @ 2021-01-30 08:54 梦中程序员 阅读(67) 评论(0) 推荐(0)
摘要:intdiv () 对除法结果取整 int intdiv ( int $dividend , int $divisor ) 说明:返回 dividend 除以 divisor 商数的整数部分。参数: dividend 被除数。 divisor 除数。 返回值: dividend 除以 divisor 阅读全文
posted @ 2021-01-29 08:59 梦中程序员 阅读(73) 评论(0) 推荐(0)
摘要:lcfirst() 使一个字符串的第一个字符小写。 string lcfirst ( string $str ) 说明:返回str的第一个字符小写了的字符串。如果str的第一个字符是字母,则将其转换为小写。 需要注意的是"字母"是由当前语言区域决定的。比如,在默认的"C"区域像日耳曼语系中的元音变音 阅读全文
posted @ 2021-01-28 08:35 梦中程序员 阅读(66) 评论(0) 推荐(0)
摘要:preg_split() 通过一个正则表达式分隔字符串。 array preg_split ( string $pattern, string $subject[, int $limit=-1[, int $flags=0]]) 说明: 通过一个正则表达式分隔给定字符串. 参数描述 pattern 阅读全文
posted @ 2021-01-27 09:15 梦中程序员 阅读(94) 评论(0) 推荐(0)
摘要:split() 用正则表达式将字符串分割到数组中。 array split ( string $pattern , string $string [, int $limit ] ) 说明: 本函数返回一个字符串数组,每个单元为 string 经区分大小写的正则表达式 pattern 作为边界分割出的 阅读全文
posted @ 2021-01-26 08:55 梦中程序员 阅读(76) 评论(0) 推荐(0)
摘要:chunk_split() 将字符串分割成小块。 string chunk_split ( string $body [, int $chunklen = 76 [, string $end = "\r\n" ]] ) 说明: 使用此函数将字符串分割成小块非常有用。例如将 base64_encode 阅读全文
posted @ 2021-01-25 13:36 梦中程序员 阅读(63) 评论(0) 推荐(0)
摘要:lcfirst () 使一个字符串的第一个字符小写 lcfirst ( string $str ) : string 参数描述 str必需。规定要转换的字符串。 返回值: 返回第一个字母小写的 str 字符串,如果是字母的话。 实例: echo lcfirst('Hello World'); //h 阅读全文
posted @ 2021-01-23 08:47 梦中程序员 阅读(39) 评论(0) 推荐(0)
摘要:ucwords () 函数把字符串中每个单词的首字符转换为大写。 ucwords ( string $str ) : string 参数描述 str必需。规定要转换的字符串。 返回值: 返回把字符串中每个单词的首字符转换为大写。 实例: echo ucwords("hello world!"); / 阅读全文
posted @ 2021-01-22 09:06 梦中程序员 阅读(58) 评论(0) 推荐(0)
摘要:strtolower () 函数把所有字符转换为小写。 strtolower( string $str ) : string 参数描述 str必需。规定要转换的字符串。 返回值: 返回把字符串中所有字符转换为小写。 实例: echo strtolower("HELLO WORLD"); //hell 阅读全文
posted @ 2021-01-21 12:57 梦中程序员 阅读(64) 评论(0) 推荐(0)
摘要:strtoupper () 函数把所有字符转换为大写。 strtoupper( string $str ) : string 参数描述 str必需。规定要转换的字符串。 返回值: 返回把字符串中所有字符转换为大写。 实例: echo strtoupper("hello world"); //HELL 阅读全文
posted @ 2021-01-21 12:54 梦中程序员 阅读(30) 评论(0) 推荐(0)
摘要:substr 函数返回字符串的一部分。注释:如果 start 参数是负数且 length 小于或等于 start,则 length 为 0。 string substr (string $string , int $start [, int $length ]) 参数描述 string 输入字符串。 阅读全文
posted @ 2021-01-19 08:39 梦中程序员 阅读(133) 评论(0) 推荐(0)
摘要:strstr() 查找字符串的首次出现。 string strstr ( string $haystack, mixed $needle[, bool $before_needle=false]) 说明:返回 haystack 字符串从 needle 第一次出现的位置开始到 haystack 结尾的 阅读全文
posted @ 2021-01-18 08:32 梦中程序员 阅读(86) 评论(0) 推荐(0)
摘要:mb_substr() 返回字符串中的一部分,不区分大小写。 string mb_substr ( string $str , int $start [, int $length = NULL [, string $encoding = mb_internal_encoding() ]] ) 说明: 阅读全文
posted @ 2021-01-15 08:56 梦中程序员 阅读(77) 评论(0) 推荐(0)
摘要:str_split() 将一个字符串转换为数组。 array str_split ( string $string [, int $split_length = 1 ] ) 参数描述 string 输入字符串。 split_length 每一段的长度。 返回值:如果指定了可选的 split_leng 阅读全文
posted @ 2021-01-14 08:52 梦中程序员 阅读(78) 评论(0) 推荐(0)
摘要:str_repeat() 重复一个字符串 。 string str_repeat ( string $input , int $multiplier ) 参数描述 input 待操作的字符串。 multiplier input 被重复的次数。 返回值:返回 input 重复 multiplier 次 阅读全文
posted @ 2021-01-13 09:05 梦中程序员 阅读(51) 评论(0) 推荐(0)
摘要:str_pad() 使用另一个字符串填充字符串为指定长度 。 string str_pad ( string $input, int $pad_length[, string $pad_string=" "[, int $pad_type=STR_PAD_RIGHT]]) 参数描述input 输入字 阅读全文
posted @ 2021-01-12 08:37 梦中程序员 阅读(149) 评论(0) 推荐(0)
摘要:str_shuffle() 随机打乱一个字符串。 string str_shuffle ( string $str ) 参数描述 str 输入字符串。返回值:返回打乱后的字符串。实例: <?php $str = 'abcdef'; $shuffled = str_shuffle($str); // 阅读全文
posted @ 2021-01-11 09:02 梦中程序员 阅读(36) 评论(0) 推荐(0)
摘要:implode() 将一个一维数组的值转化为字符串。 string implode ( string $glue , array $pieces ) 参数描述 glue 默认为空的字符串。 pieces 你想要转换的数组。返回值:返回一个字符串,其内容为由 glue 分割开的数组的值。 实例: <? 阅读全文
posted @ 2021-01-09 16:46 梦中程序员 阅读(66) 评论(0) 推荐(0)
摘要:explode() 使用一个字符串分割另一个字符串。 array explode( string $delimiter , string $string [, int $limit ]) 参数描述delimiter 边界上的分隔字符。 string 输入的字符串。 limit 如果设置了 limit 阅读全文
posted @ 2021-01-08 09:00 梦中程序员 阅读(107) 评论(0) 推荐(0)
摘要:ltrim() 删除字符串开头的空白字符(或其他字符)。 string ltrim ( string $str[, string $character_mask]) 参数描述str 输入的字符串。 character_mask 通过参数 character_mask,你也可以指定想要删除的字符,简单 阅读全文
posted @ 2021-01-08 08:56 梦中程序员 阅读(102) 评论(0) 推荐(0)