⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 鼠标点亮图片.txt

📁 网页特效的代码,在美化网页时有很大的作用
💻 TXT
字号:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head>

<body bgcolor="#000000" text="#FFFF00">
<p>
  <style>
<!--

#myimage{
filter:light
}

-->
              </style>
  <img id="myimage" src="052.gif" width="400" height="340"> 
  <script language="JavaScript1.2">

s = 50; // the size of the spotlight
vp = 2; // the visibility percent of the picture
startx = 0; // the top position of your sportlight into the image (on start)
starty = 0; // the left position of your spotlight into the image (on start)


//////////////////////////////////////////////////////////////////
//		No need to edit below this line			//
//////////////////////////////////////////////////////////////////

var IE = document.all?true:false

function moveL()
{
xv = tempX;
yv = tempY;
myimage.filters.light.MoveLight(1,xv,yv,s,true);
}

if (IE&&myimage.filters)
document.all.myimage.onmousemove = getMouseXY;
var tempX = 0
var tempY = 0


function getMouseXY(e) {
tempX = event.offsetX
tempY = event.offsetY

  if (tempX < 0){tempX = 0}
  if (tempY < 0){tempY = 0}
  if (t)
  {  
   moveL();
  }

  return true
}

var xv = startx;
var yv = starty;
var t= true;
if (IE&&myimage.filters){
myimage.style.cursor="hand";
myimage.filters.light.addAmbient(255,255,255,vp)
myimage.filters.light.addPoint(startx,starty,s,255,255,255,255)
}

              </script>
</p>
<p>&lt;html&gt;<br>
  &lt;head&gt;<br>
  &lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=gb2312&quot; /&gt;<br>
  &lt;title&gt;无标题文档&lt;/title&gt;<br>
&lt;/head&gt;</p>
<p>&lt;body bgcolor=&quot;#000000&quot; text=&quot;#FFFF00&quot;&gt;<br>
  &lt;style&gt;<br>
  &lt;!--</p>
<p>#myimage{<br>
  filter:light<br>
  }</p>
<p>--&gt;<br>
  &lt;/style&gt;<br>
  &lt;img id=&quot;myimage&quot; src=&quot;052.gif&quot; width=&quot;400&quot; height=&quot;340&quot;&gt; <br>
  &lt;script language=&quot;JavaScript1.2&quot;&gt;</p>
<p>s = 50; // the size of the spotlight<br>
  vp = 2; // the visibility percent of the picture<br>
  startx = 0; // the top position of your sportlight into the image (on start)<br>
  starty = 0; // the left position of your spotlight into the image (on start)<br>
</p>
<p>//////////////////////////////////////////////////////////////////<br>
  //		No need to edit below this line			//<br>
  //////////////////////////////////////////////////////////////////</p>
<p>var IE = document.all?true:false</p>
<p>function moveL()<br>
  {<br>
  xv = tempX;<br>
  yv = tempY;<br>
  myimage.filters.light.MoveLight(1,xv,yv,s,true);<br>
  }</p>
<p>if (IE&amp;&amp;myimage.filters)<br>
  document.all.myimage.onmousemove = getMouseXY;<br>
  var tempX = 0<br>
  var tempY = 0<br>
</p>
<p>function getMouseXY(e) {<br>
  tempX = event.offsetX<br>
  tempY = event.offsetY</p>
<p> if (tempX &lt; 0){tempX = 0}<br>
  if (tempY &lt; 0){tempY = 0}<br>
  if (t)<br>
  { <br>
  moveL();<br>
  }</p>
<p> return true<br>
  }</p>
<p>var xv = startx;<br>
  var yv = starty;<br>
  var t= true;<br>
  if (IE&amp;&amp;myimage.filters){<br>
  myimage.style.cursor=&quot;hand&quot;;<br>
  myimage.filters.light.addAmbient(255,255,255,vp)<br>
  myimage.filters.light.addPoint(startx,starty,s,255,255,255,255)<br>
  }</p>
<p>&lt;/script&gt;<br>
  &lt;/body&gt;<br>
  &lt;/html&gt;<br>
</p>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -