This article describes the commonly used pop-up ads and rear projection ad implementation methods in JavaScript. Share it for your reference. The specific analysis is as follows:
Pop-up ads and background ads are used more frequently on large websites and are also a must-have code for webmasters. This code snippet includes two forms: pop-up ads and rear projection ads. You can choose as you like according to your needs.
Note: This type of advertisement is not recommended for everyone to use. Most browsers will block this type of AD for everyone to learn.
Copy the code as follows: <html>
<head>
<title>Commonly used pop-up ads and rear projection ad codes in JavaScript</title>
</head>
<body>
<!--Repost-projection-->
<SCRIPT language=JavaScript1.2>
function openWindowBack() {
var popUpWin2 = open("//www.VeVB.COM", "popUpWin2", "width=1,height=1,top=4000,left=3000");
}
try{
aryADSeq.push("openWindowBack()");
}catch(e){
openWindowBack();
}
</SCRIPT>
<!--Rearcast end->
<!--Front pop-up window-->
<SCRIPT language=JavaScript1.2>
function openWindowFront() {
var popUpWin = open("/default.html", "popUpWin", "toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbar=no,resizable=no,copyhistory=yes,width=300,height=250");
}
try{
aryADSeq.push("openWindowFront()");
}catch(e){
openWindowFront();
}
</SCRIPT>
<br />
</body>
</html>
I hope this article will be helpful to everyone's JavaScript programming.