设置或获取对象指定的文件名或路径。 window.location.pathname例:http://localhost:8086/topic/index?topicId=361alert(window.location.pathname); 则输出:/topic/index设置或获取整个 ...
设置或获取对象指定的文件名或路径。 window.location.pathname例:http://localhost:8086/topic/index?topicId=361alert(window.location.pathname); 则输出:/topic/index设置或获取整个 ...
//获取多个地址栏信息,name为地址栏参数名,可以传递多个参数 // 形式为 .html?id=12&a=2 function getQueryString(name){ var reg = new RegExp("(^|&)"+ name ...
有的时候需要获取页面名称,为此我在这里封装了一个方。 一、分别根据传递不同的参数,获取到html页面的名称。 通过传递参数,获取到html页面的名称;参数params 以下是参数解释说明 (1)params=1,只获取页面名称,不带.html后缀 1.1 例如 url ...
获取上一个页面的一个URL,这个URL一般做一个页面的跳转 window.location.href <script>window.location.href="http://www.baidu.com"</script> 获取一个页面的主机名 ...
当前url:http://localhost:8080/CarsiLogCenter_new/idpstat.jsp?action=idp.sptopn request.getRe ...
//获取URL参数function getQueryString(name) { var reg = new RegExp("(^|/?|&)" + name + "=([^&]*)(&|$)", "i"); var r = decodeURIComponent ...
...
function GetRequest() { var url = location.search; var theRequest = new Object(); if (url.indexOf("? ...