JS实现获取当前URL和来源URL的方法

time:09-17  人气:5284       返回分类   返回首页 

这篇文章主要介绍了JS实现获取当前URL和来源URL的方法,涉及javascript针对页面document属性操作的相关技巧,需要的朋友可以参考下


本文实例讲述了JS实现获取当前URL和来源URL的方法。分享给大家供大家参考,具体如下:

index.html:

1
2
3
4
5
6
7
8
9
10
11
<!DOCTYPE html>
<html lang="zh-cn">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
<title>新建H5模板</title>
</head>
<body>
<a href="demo.html">链接</a>
</body>
</html>

demo.html:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<!DOCTYPE html>
<html lang="zh-cn">
<head>
<meta charset=
------------ 官方公告与活动通知 ------------
  
  • Notice on Strengt...
  • About Notice of C...
  • Notice on Version...
  • Webmeng China 202...
  • Regarding the adj...
  • 责任编辑:


    查看原文      
    最新评论   点击评论  
    您好!没有相关评论,请 点击评论

    注册         登录
           

    ------------ 搜寻搜索提供的广告| Soufind Ads ------------
    ------------ 搜寻搜索提供的广告| Soufind Ads ------------
    返回新闻中心