strrchr()

It finds the last occurrence of a character in a string

Example

<?php
echo strrchr(“phpcodeccr”,”co”);
?>

Output

cr

Share