url

Formats a string for use in a URL.

This function converts blank spaces and reserved characters to an escape sequence.

Type and Usage

Parameters

The only parameter is the string.

Output

Returns a string formatted for use in a URL.

Example

Formats the string home page as home%20page:

<$url("home page")$>

Formats the string home/page as home%2fpage:

<$url("home/page")$>

Formats the string home?page as home%3fpage:

<$url("home?page")$>