Hi all,
I have this: $path = "image.html?img_id=10";
I want to get rid of the value after the ? so path will be $path = "image.html"
How can I do it? of course the value after the ? can be different then img_id=10
any ideas?
Try this...
$pathShort = preg_replace( "/(\?.*)$/", "", $path );
A combination of [man]strpos[/man] and [man]substr[/man].