Text_Diff::trimNewlines
Removes trailing newlines from a line of text. This is meant to be used with array_walk().
Метод класса: Text_Diff{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$result = Text_Diff::trimNewlines( $line, $key );
- $line(строка) (обязательный) (передается по ссылке — &)
- The line to trim.
- $key(int) (обязательный)
- The index of the line in the array. Not used.
Код Text_Diff::trimNewlines() Text Diff::trimNewlines WP 7.1
static function trimNewlines(&$line, $key)
{
$line = str_replace(array("\n", "\r"), '', $line);
}