Fully Qualified Name: | Laminas\Filter\UriNormalize |
Extends: | AbstractFilter |
Name | Description | Defined By |
---|---|---|
__construct() | Sets filter options | UriNormalize |
__invoke() | Invoke filter as a command | AbstractFilter |
filter() | Filter the URL by normalizing it and applying a default scheme if set | UriNormalize |
getOptions() | Retrieve options representing object state | AbstractFilter |
hasPcreUnicodeSupport() | AbstractFilter | |
setDefaultScheme() | Set the default scheme to use when parsing scheme-less URIs | UriNormalize |
setEnforcedScheme() | Set a URI scheme to enforce on schemeless URIs | UriNormalize |
setOptions() | AbstractFilter |
Sets filter options
Parameter Name | Type | Description |
---|---|---|
$options | array|\Traversable|null |
Returns:
Invoke filter as a command
Proxies to {@link filter()}
Parameter Name | Type | Description |
---|---|---|
$value | mixed |
Returns: mixed
Filter the URL by normalizing it and applying a default scheme if set
Parameter Name | Type | Description |
---|---|---|
$value | string |
Returns: string
Retrieve options representing object state
Returns: array
Returns: bool
Set the default scheme to use when parsing scheme-less URIs
The scheme used when parsing URIs may affect the specific object used to normalize the URI and thus may affect the resulting normalize URI.
Parameter Name | Type | Description |
---|---|---|
$defaultScheme | string |
Returns: self
Set a URI scheme to enforce on schemeless URIs
This allows forcing input values such as 'www.example.com/foo' into 'http://www.example.com/foo'.
This should be used with caution, as a standard-compliant URI parser would regard 'www.example.com' in the above input URI to be the path and not host part of the URI. While this option can assist in solving real-world user mishaps, it may yield unexpected results at times.
Parameter Name | Type | Description |
---|---|---|
$enforcedScheme | string |
Returns: self
Parameter Name | Type | Description |
---|---|---|
$options | array|\Traversable |
Returns: self