url.scheme

This function returns the URL scheme.

Syntax

url.scheme(rawURLString)

Arguments

Argument

Type

Description

rawURLString

string

Raw URL string

Returns

Type

Description

string

The URL scheme

Examples

The function url.scheme("https://example.com:8080/root-path/sub-path?query=example+query+%2F+question#fragment") returns https.