Chop

Chop -- remove trailing whitespace

Description

string chop(string str);

Returns the argument string without trailing whitespace, including newlines.

Example 1. chop() example

$trimmed = Chop($line);

See also trim().