Home > Article > Web Front-end > How to set up so that when you click the hyperlink, it will be a game page, and then click again to get the desired page_html/css_WEB-ITnose
I will not go to a site like this a second time. When I encounter some browsers that provide website security prompts, sites like yours will be directly blacklisted.
4ec11beb6c39d0703d1751d203c17053
document.onclick=function()
{
window.location.href="Normal page address";
}
2cacc6d41bbb37262a98f745aa00fbf0
You might as well start with a normal page, and when you click it, a new window will pop up the game page
The bad guy, I didn’t tell you
Actual connection When it comes to the game page, the real page is implemented using a script to set the location. However, please note that the connection must set target="_blank". Otherwise, the script will not be executed if the current page is redirected.
<a href="http://www.coding123.net" onclick="gotoURL(this,'http://bbs.csdn.net')" target="_blank">CSDN</a><script type="text/javascript"> function gotoURL(a, realURL) { setTimeout(function () { top.location.href = realURL; }, 10); }</script>
Not that To make such a website, there are some websites like this. If I want to know how such a website is made, I will not go there a second time. When I encounter some browsers that provide website security prompts, sites like yours will be directly blacklisted.
When I looked at some comic websites and various game pages, I was very curious about how these codes are written. The original poster is bad, I won’t tell you.
When actually connecting, the game page is used, and the real page uses a script. Set the location implementation, but note that the connection must set target="_blank", otherwise the script will not be executed if the current page is redirected
HTML code
664a1ee14e61fc6873ba04b12bdbdf5bCSDN5db79b134e9f6b82c0b36e0489ee08ed