normalize_whitespace()

 

File: wp-includes/formatting.php

function normalize_whitespace( $str ) {
	$str = trim( $str );
	$str = str_replace( "/r", "/n", $str );
	$str = preg_replace( array( '//n+/', '/[ /t]+/' ), array( "/n", ' ' ), $str );
	return $str;
}

参数:normalize_whitespace( string $str )

The string to normalize.

(字符串)规范化字符串。

$str

(string)
(Required)
The string to normalize.

{acontent3}

You must log in before being able to contribute a note or feedback.

5.00% (1) 次Baidu访问
5.00% (1) 次Google访问
85.00% (17) 次Sogou访问
5.00% (1) 次sm访问
  • 蜘蛛:Baidu,1次,更新时间:2019-04-24 20:35:32
  • 蜘蛛:Google,1次,更新时间:2019-04-29 09:12:30
  • 蜘蛛:Sogou,17次,更新时间:2019-05-25 17:17:54
  • 蜘蛛:sm,1次,更新时间:2019-05-26 04:15:05

参与评论