trim() Function

Function

trim( text )

Removes all unnecessary spaces from the text. Only single spaces between words are considered necessary.

Parameters

Keyword Type Description

text

Text

The string of text from which unnecessary spaces are to be removed.

Returns

Text

Examples

You can experiment with this function in the test box below.

Test Input

trim(" this text needs trimming ") returns this text needs trimming

Open in Github Built: Fri, Oct 22, 2021 (11:09:30 AM)

On This Page

FEEDBACK