HTML 整人代码

HTML 整人代码,第1张

<script language="javascript">

function hr(){

alert('你关不掉的^_^')

hr()

}

</script>

<body onLoad="hr()">

</body>

做坏事了 面壁去。。

<html>

<body>

<script>

var i

for(i=5i>4i++)

{

alert("d出一个文本框")

}

</script>

</body>

</html>

复制到记事本中,后缀名改成.html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">

<head>

<meta http-equiv="Content-Type" content="text/htmlcharset=UTF-8">

<title>Document</title>

<script type="text/javascript">

function myadd(obj,e,fn){

if(obj.attachEvent){

obj.attachEvent("on"+e, fn)

}else{

obj.addEventListener(e,fn,false)

}

}

myadd(window, 'load',function(){

var box1 = document.getElementById("box1")

var close = document.getElementById("close")

var nr = document.getElementById("nr")

var i = 0

var shuzu = [

'哈哈你被整了!1',

'哈哈你被整了!2',

'哈哈你被整了!3',

'哈哈你被整了!4',

'哈哈你被整了!5',

'哈哈你被整了!6',

'哈哈你被整了!7',

'哈哈你被整了!8',

'哈哈你被整了!9',

'哈哈你被整了!0','哈哈你被整了!1',

'哈哈你被整了!2'

]

close.onclick = function(){

i++

if(i == 12){

i = 0

}

nr.innerHTML = shuzu[i]

box1.style.display = 'none'

window.setTimeout(function(){

box1.style.display = 'block'

},400)

}

})

</script>

</head>

<style type="text/css">

.box1{

background:#ccc

width:200px

margin:200px auto

}

.bgs{

position:fixed

top: 0px

left: 0px

background:rgba(0,0,0,0.4)

width:100%

height: 100%

}

.box1 .close{

font-size: 18px

line-height:40px

background:red

color:white

cursor: pointer

}

</style>

<body>

<div class="bgs" id = 'box1'>

<div class="box1" >

<div class="close" id = 'close' style = 'text-align:ceter'>点我关闭吧 x</div>

<div class="nr" id= 'nr'>哈哈你被整了!</div>

</div>

</div>

</body>

</html>


欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/zaji/7251358.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2023-04-03
下一篇 2023-04-03

发表评论

登录后才能评论

评论列表(0条)

保存