$hostname = "http://localhost/test/123.jpg";
$expname = explode ("/", $hostname);
// Point to the last element of array
$lastV = end($expname);
// Get the current element of array
$lastV = pos($expname);
Получить последнее значение используя PHP explode
12 лет назад

