I am a little confused with the PHP manual regarding the charlist parameter. I have the following string:
1234567-1.jpg
I need to drop the -1.jpg
What do I need to use in the charlist part of the arguement to make it happen?
Thanks in advance.
Matt
$string = "1234567-1.jpg"; $var = substr($string, 0, -6);
Thank you. I remember looking at the substr function, and I remember seeing that it did exactly what you suggested. I must need more sleep...
Thanks again.