ends_with¶
The ends_with()
function checks if a given value ends with a specified suffix.
Syntax¶
Parameters¶
value
: The value to check (field name, bytes).suffix
: The suffix to match against (literal bytes).
Return Value¶
Returns a boolean value: true
if the value ends with the specified suffix, false
otherwise.
Example¶
Use Cases¶
- Filtering requests based on file extensions.
- Identifying specific types of resources.
- Implementing content-type based routing.