php截取字符串,该怎么解决
程序员文章站
2022-06-12 17:38:19
...
php截取字符串
/book/shopping/%E9%95%BF%E8%A3%99
php如何截取book/之后/%E9%95%BF%E8%A3%99之前的字符串
------解决方案--------------------
/book/shopping/%E9%95%BF%E8%A3%99
php如何截取book/之后/%E9%95%BF%E8%A3%99之前的字符串
------解决方案--------------------
- PHP code
$ar=preg_split('/[\/]/','/book/shopping/%E9%95%BF%E8%A3%99',-1,PREG_SPLIT_NO_EMPTY); echo $ar[1];相关文章
相关视频