如何在PHP中捕获当前页面的url [英] how to capture the current page url in PHP

查看:34
本文介绍了如何在PHP中捕获当前页面的url的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用PHP中的参数获取当前页面的URL

I want to get the current page URL with parameters in PHP

网址是

http://localhost/omni/abc.php#def=S6ZT4b9MEsFGDzo

我想获取#符号后的url部分

I want to get the url part after the # sign

推荐答案

URL 中 # 之后的任何内容仅在客户端处理.它甚至没有传递给服务器的请求,因此您无法直接访问它.

Anything after the # in a URL is only handled on the client-side. It is not even passed to the request to the server, so there is no way you can directly access it.

这篇关于如何在PHP中捕获当前页面的url的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆