(编辑:jimmy 日期: 2026/1/29 浏览:2)
本文主要介绍的是php使用函数pathinfo() 、parse_url()和basename()解析URL的实例代码,下面话不多说,直接来看代码
实例代码如下:
1、利用pathinfo解析URL
<"http://localhost/index.php"); print_r($test); "htmlcode">Array ( [dirname] => http://localhost //url的路径 [basename] => index.php //完整文件名 [extension] => php //文件名后缀 [filename] => index //文件名 )2、利用parse_url()函数解析
<"http://localhost/index.php"); print_r($test); "htmlcode">Array ( [scheme] => http //使用什么协议 [host] => localhost //主机名 [path] => /index.php //路径 [query] => name=tank&sex=1 // 所传的参数 [fragment] => top //后面根的锚点 )3、使用basename()解析
<"http://localhost/index.php"); echo $test; "htmlcode">index.php"color: #ff0000">总结以上就是这篇文章的全部内容了,希望本文的内容对大家的学习或者工作能带来一定的帮助,如果有疑问大家可以留言交流。
高通和谷歌日前宣布,推出首次面向搭载骁龙的Windows PC的优化版Chrome浏览器。
在对骁龙X Elite参考设计的初步测试中,全新的Chrome浏览器在Speedometer 2.1基准测试中实现了显著的性能提升。
预计在2024年年中之前,搭载骁龙X Elite计算平台的PC将面世。该浏览器的提前问世,有助于骁龙PC问世就获得满血表现。
谷歌高级副总裁Hiroshi Lockheimer表示,此次与高通的合作将有助于确保Chrome用户在当前ARM兼容的PC上获得最佳的浏览体验。