小编Pig*_*igi的帖子

从php中的url中提取值

我有一个类似于此的URL:

http://somethinfs.com/folder/134039/the_title_of_somethings.html
http://somethinfs.com/folder/184738/the_title_of_somethings_else.html

从这个URL,我需要提取"134039"和"184738".我试过使用strpos和substr但它不起作用,它只是回复我.html.

php url substr strpos

1
推荐指数
1
解决办法
139
查看次数

标签 统计

php ×1

strpos ×1

substr ×1

url ×1