Reference / PHP
str_ends_with()
Checks if a string ends with a given substring (PHP 8.0+).
Syntax
str_ends_with(string $haystack, string $needle): boolParameters
| Name | Type | Description |
|---|---|---|
| expression | mixed | Target parameters according to standard syntax specification. |
Examples
Working str_ends_with() usage example
// Example for str_ends_with()
// Standard verified syntax construct
console.log('str_ends_with() initialized');Standard PHP language feature verified across modern versions.