JS implementation of the mouse arrow into a burning candle effect method _javascript Tips

Source: Internet
Author: User
Tags event listener

This article describes the JS implementation of the mouse arrow into a burning candle effect method. Share to everyone for your reference. Specifically as follows:

This is a complete mouse-arrow beautification effect of the JS code, through this JS code, the mouse arrow plus a style, burning candles. This is also very old code, only in the IE8 and the following browser run, the code is as follows:

Copy Code code as follows:
<meta http-equiv= "Content-type" content= "text/html; charset=gb2312 ">
<title> very distinctive Fluorescent mouse </title>
<body id= "Mybody" style= "Filter:light (enabled=1);" bgcolor= "#ffffff" text= "#000000" >
<div id= "Layer1" style= "HEIGHT:32; left:66; Position:absolute; top:41; Width:52 ">
<dd>
<div align= "Right" >

</div>
</dd>
</div>
<table border= "0" width= "100%" >
<tr>
&LT;TD width= "82%" ><font face= "song Body" color= "#FF00FF" style= "font-size:9pt" >
</font><span style= "Font-size:9pt" >
Absrtact: HTML5 source code, canvas instance, canvas animation
A Html5_canvas practicing program, with canvas tags <br><br><br> draw a simple animation effect: analog intersection green light,<br><br> car walk; Red light, car stop effect, The animation effect is more coarse,<br> for beginners to refer to. HTML5 program, currently does not support IE.
<br> shooting game, start after the game,<br> with the mouse to click the whereabouts of objects,<br> shooting explosive objects, the resulting game quality fine,<br> animation smooth, testing, please use Firefox or Chrome browser, &LT;BR &GT;IE8 The following version cannot run this game. <br> Although the game function is not a powerful,<br><br> but it is used to HTML5 the basic skills,<br><br><br> in addition, some game operation of the JS class is also want to be a good choice. <br><br>
Based on HTML5 offline storage instance, when the page is loaded, the application uses an OnLoad function to verify that the phase <br><br> data is already in the local cache and adds a <br><br> welcome window , add an event listener to <br><br> and listen for a storage event,<br><br> application can respond to localstorage changes <br><br > Verification Browser supports localstorage function,<br><br> set data to cache, erase data and so on.
</span></td>
</tr>
</table>
<script language= "VBScript" >
Dim Red,gre,blu
Dim x,y,z
red=255
gre=255
Blu=0
z=100
Sub Window_onload ()
Call Mybody.filters.light.addPoint (0,0,z,red,gre,blu,100)
Mybody.style.cursor= "Hand"
End Sub
Sub Document_onmousemove ()
X=window.event.x
Y=window.event.y
Call Mybody.filters.Light.MoveLight (0, X, y, 100, 1)
End Sub
</script>
<script language= "JavaScript" >
This is the function that moves the layer
function Move_layer ()
{
layer1.style.left=event.clientx+document.body.scrollleft-50;
layer1.style.top=event.clienty+document.body.scrolltop-20;
}
This means that if the mouse moves, the "Move_layer" function is called
Document.onmousemove =move_layer;
</script>
</body>

I hope this article will help you with your JavaScript programming.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.