Hai dòng trên con trỏ chuột

Một phần của tài liệu TONG HOP CODE HTML pot (Trang 66 - 69)

<!—---Tổng hợp code HTML - Copyright Mạnh Hạo Nhiên---> <!--<head>--> <!--</head>--> <!--<body>--> <!--<html>--> <!--<head>--> <style>

#leftright, #topdown{position: absolute;left: 0;top: 0;width: 1px;height: 1px;layer- background-color: #FF0000;background-color: #FF0000;z-index: 100;font-size: 1px;}

</style>

<!--</head>--> <!--<body>-->

<div id="leftright" style="width:expression(document.body.clientWidth-2)"></div> <div id="topdown" style="height:expression(document.body.clientHeight-2)"></div> <script language="JavaScript">

if (document.all&&!window.print){

leftright.style.width=document.body.clientWidth-2 topdown.style.height=document.body.clientHeight-2

}

else if (document.layers){

document.leftright.clip.width=window.innerWidth document.leftright.clip.height=1

document.topdown.clip.width=1

document.topdown.clip.height=window.innerHeight

}

function followmouse1(){

leftright.style.pixelTop=document.body.scrollTop+event.clientY+1 topdown.style.pixelTop=document.body.scrollTop

if (event.clientX<document.body.clientWidth-2)

topdown.style.pixelLeft=document.body.scrollLeft+event.clientX+1 else

topdown.style.pixelLeft=document.body.clientWidth-2

}

function followmouse2(e){

document.leftright.top=e.y+1 document.topdown.top=pageYOffset document.topdown.left=e.x+1

}

if (document.all)

document.onmousemove=followmouse1 else if (document.layers){

window.captureEvents(Event.MOUSEMOVE)

window.onmousemove=followmouse2

}

function regenerate(){

window.location.reload() }

function regenerate2(){

setTimeout("window.onresize=regenerate",400) }

if ((document.all&&!window.print)||document.layers)

window.onload=regenerate2 </script> <!--</body>--> <!--</html>--> <!--</body>--> <!--</html>--> 69. văn bảntuyệt đẹp

<!—---Tổng hợp code HTML - Copyright Mạnh Hạo Nhiên---> <!--<html>-->

<!--<head>--> <!--</head>--> <!--<body>-->

<SPAN id=js4irtext style="WIDTH: 100%; ">www.htmlfreecodes.com</SPAN> <SCRIPT language="javascript" link="www.htmlfreecodes.com">

var from = 4;

var to = 12;

var speed = 1;

var textcolor = "#aabbdd";

var i = to;

var j = 0;pd();

function pu(){

if (!document.all)

return

if (i < to){js4irtext.style.filter = "Glow(Color=" + textcolor + ", Strength=" + i + ")";i+ +;theTimeout = setTimeout('pu()',speed);

return 0;}

if (i = to){theTimeout = setTimeout('pd()',speed);

return 0;}}

function pd(){

if (!document.all)

return

if (i > from)

{js4irtext.style.filter = "Glow(Color=" + textcolor + ", Strength=" + i + ")";i--;theTimeout = setTimeout('pd()',speed);

return 0;}

if (i = from){theTimeout = setTimeout('pu()',speed);

return 0;}} </SCRIPT> <!--</body>--> <!--</html>--> <br /> 70. bóng văn bản

<!—---Tổng hợp code HTML - Copyright Mạnh Hạo Nhiên--->

<html> <head>

<script type = "TEXT/JAVASCRIPT" LANGUAGE = "JAVASCRIPT">

function doShadow(newDiretction){

if (document.all && newDiretction < 360) { newDiretction += 10

document.all.dropText.style.filter="shadow(direction=" + newDiretction + ")"

setTimeout("doShadow(" + newDiretction + ")" , 100) }

}

</script>

<STYLE TYPE="TEXT/CSS">

#dropText {width: 500px; height: 100px; font-size: 36px; filter:

shadow(direction=90)}

</head> <body> <DIV ID="dropText"> htmlfreecodes.com </DIV> </body> </html> 71. đánh dấu tất cả - Bỏ dấu tất cả

<!—---Tổng hợp code HTML - Copyright Mạnh Hạo Nhiên--->

<HEAD>

<SCRIPT LANGUAGE="JavaScript">

<!-- Begin

var checkflag = "false";

function check(field) {

if (checkflag == "false") {

for (i = 0; i < field.length; i++) { field[i].checked = true;}

checkflag = "true";

return "Uncheck All"; }

else {

for (i = 0; i < field.length; i++) { field[i].checked = false; }

checkflag = "false";

return "Check All"; } } // End --> </script> </HEAD> <!-- CONTINUE --> <BODY> <center>

<form name=myform action="" method=post> <table>

<tr><td>

<b>Your Favorite Scripts & Languages</b><br>

<input type=checkbox name=list value="1">Java<br> <input type=checkbox name=list value="2">JavaScript<br> <input type=checkbox name=list value="3">ASP<br>

<br>

<input type=button value="Check All" onClick="this.value=check(this.form.list)"> </td></tr>

</table> </form> </center>

Một phần của tài liệu TONG HOP CODE HTML pot (Trang 66 - 69)

Tải bản đầy đủ (DOCX)

(74 trang)
w