Hi, is there a php string function to trim a string after a particular character. I had a look on the php.net site and did a google search but couldn't find anything. The only solution i could think of was explode and then grab the first part of the array but thats not the most elegant solution.
For example
$sting = "/gallery/image?a=b";
$string = imaginary_function($string,'?');
echo $string; //echoes "/gallery/image"
Does anyone know of a good cheat sheet for php string manipulation functions? Thanks