View the Complete Blog on ZCE
$foo = 'charanjeet/working/with/php';
echo strrpos($foo, '/', -5);
Answer: 18
It will start searching it reverse direction after ignoring 5 five characters.
It will then return the position of the / after working, from the beginning
$foo = 'charanjeet/working/with/php';
echo strrpos($foo, '/', -5);
Answer: 18
It will start searching it reverse direction after ignoring 5 five characters.
It will then return the position of the / after working, from the beginning
No comments:
Post a Comment