HY我要搶例如每名:
我有數據
PHP切特定字符串
01.jpg02.jpg03.jpg10599335_899600036724556_4656814811345726851_n.jpg11693824_1051832718167953_6310308040295800037_n.jpg11709788_1051835281501030_8503525152567309473_n.jpg12042832_1103685106316047_3711793359145824637_n.jpg
我嘗試這樣,但不是爲我工作
$str = $_POST['name'];
print_r (explode(".jpg", $str));
foreach ($str as $key => $value) {
echo $value.'<br>';
}
你想抓住與擴展,比如'10599335_899600036724556_4656814811345726851_n.jpg'文件? – RomanPerekhrest
您的預期產量是多少? – anubhava
@RomanPerekhrest是的,這是怎麼回事 – b4dQuetions