Home > headlines > Detailed introduction and usage of php trim function

Detailed introduction and usage of php trim function

不言
Release: 2018-05-09 15:01:56
Original
2708 people have browsed it

Some usages of PHP trim() function, usage of phptrim function String trim ( string $str [, string $charlist ] ) - Remove blank characters (or other characters) at the beginning and end of the string When the second parameter is empty, the trim() function will remove spaces, tabs, line feeds, carriage returns, vertical tabs, etc. by default. When the second parameter is added,   1) trim(' \"string\"', '\"sg'); // Final output: \"strin   2) trim(' \"string\" ', '\"sg'); // Final output: \"string\" ​​ 2)trim('\"string\"', '\"sg'); // Final output: trin Therefore, the trim() function first removes the blank characters at the beginning and end of the characters, and then filters out the given characters (list) to be removed. It is also suitable for

1. Some of the PHP trim() functions Usage, phptrim function usage_PHP tutorial

#Introduction: Some usages of PHP trim() function, phptrim function usage. Some uses of the PHP trim() function, phptrim function usage string trim ( string $str [, string $charlist ] ) - remove blank characters (or other characters) at the beginning and end of the string trim() function

2. Some usages of PHP trim() function, phptrim function usage

Introduction: Some usages of PHP trim() function, phptrim function usage. Some usages of PHP trim() function, phptrim function usage string trim ( string $str [, string $charlist ] )

[Related Q&A recommendations]:

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template