当前位置:网站首页>Several ways of JS jump link
Several ways of JS jump link
2022-07-07 14:42:00 【Snail games】
1、 Jump Links Open... In the current window
1 |
|
2、 Jump Links Open in new window
1 |
|
3、 Jump Links Back to previous page
1 |
|
4、 Jump Links
1 |
|
self Refers to the current window object , Belong to window The top object .
location.href It means something window Object's url The address of
self.location.href Of the current window url Address , Get rid of self The default is... Of the current window url Address , Generally used to prevent external references
top.location.href: Citing test.html page url Of Of the parent window object url
If your web address is :http://www.a.com, Others are http://www.b.com, He uses... On his page iframe Wait for the frame to quote your http://www.a.com, So you can use :
1 2 3 |
|
To go to your page ,top Refers to the main window , here top.location.href return http://www.b.com;
http://www.b.com!=http://www.a.com, Return to true (true), Then the web page will be redirected to your web page , It can prevent theft .
边栏推荐
猜你喜欢
低代码平台中的数据连接方式(下)
2022年13个UX/UI/UE最佳创意灵感网站
《微信小程序-进阶篇》组件封装-Icon组件的实现(一)
潘多拉 IOT 开发板学习(HAL 库)—— 实验12 RTC实时时钟实验(学习笔记)
Leetcode one question per day (636. exclusive time of functions)
华为云数据库DDS产品深度赋能
Multi merchant mall system function disassembly lecture 01 - Product Architecture
Substance Painter筆記:多顯示器且多分辨率顯示器時的設置
#yyds干货盘点# 解决名企真题:交叉线
Computer win7 system desktop icon is too large, how to turn it down
随机推荐
2022云顾问技术系列之高可用专场分享会
Data Lake (IX): Iceberg features and data types
Beginner JSP
Use case diagram
WebRTC 音频抗弱网技术(上)
Leetcode - Sword finger offer 05 Replace spaces
Notes de l'imprimante substance: paramètres pour les affichages Multi - écrans et multi - Résolutions
Leetcode——236. The nearest common ancestor of binary tree
What is cloud primordial? This time, I can finally understand!
2022PAGC 金帆奖 | 融云荣膺「年度杰出产品技术服务商」
Huawei cloud database DDS products are deeply enabled
Pandora IOT development board learning (HAL Library) - Experiment 12 RTC real-time clock experiment (learning notes)
「2022年7月」WuKong编辑器更版记录
C# 6.0 语言规范获批
MLGO:Google AI发布工业级编译器优化机器学习框架
6. Electron borderless window and transparent window lock mode setting window icon
Bill Gates posted his resume 48 years ago: "it's not as good-looking as yours."
Full details of efficientnet model
Simple steps for modifying IP of sigang electronic scale
13 ux/ui/ue best creative inspiration websites in 2022