Phantasmal MUD Lib for DGD

Phantasmal Site > Phantasmal API > API Listing > trim_whitespace

API Function: trim_whitespace

Summary:
remove leading and trailing whitespace from a string

Defined In LPC Object:
/usr/common/sys/stringd.c

Prototype:
string trim_whitespace(string str)

Can Be Called By:
Anybody

Description:

Returns the string with all leading and trailing whitespace removed. This may result in the empty string. If nil is passed in, it is also returned.

There is a Phrase equivalent to this defined in the intl_phrase library.

Return Value:

The new string.

Errors:
Normally none.

See Also:
char_is_whitespace , is_whitespace , intl_phrase:trim_whitespace