时间:2021-07-01 10:21:17 帮助过:48人阅读
//可以不需要正则$url = 'http://abc/innd/ffdss/Jack';echo substr($url, strrpos($url, '/')+1);
//可以不需要正则$url = 'http://abc/innd/ffdss/Jack';echo substr($url, strrpos($url, '/')+1);
$s = 'http://abc/innd/ffdss/Jack';preg_match('#/([^/]+)$#', $s, $m);echo $m[1];