endsWith() public static method
Check if given string ends with specified substring.
Binary and multibyte safe.
public static boolean endsWith ( $string, $with, $caseSensitive = true ) | ||
---|---|---|
$string | string |
Input string to check |
$with | string |
Part to search inside of the $string. |
$caseSensitive | boolean |
Case sensitive search. Default is true. When case sensitive is enabled, $with must exactly match the ending of the string in order to get a true value. |
return | boolean |
Returns true if first input ends with second input, false otherwise |
Please login to continue.