1
<html>
2
<head>
3
<title></title>
4
<script language="javascript">
5
var min=10;
6
var max=100;
7
var number=1;
8
function OnMouseOver(obj)
9
{
10
if(obj.changing)
11
clearInterval(obj.changing);
12
obj.changing=setInterval("add("+obj.id+")",10);
13
}
14
function OnMouseOut(obj)
15
{
16
if(obj.changing)
17
clearInterval(obj.changing);
18
obj.changing=setInterval("sub("+obj.id+")",10);
19
}
20
function add(obj)
21
{
22
if(obj.filters.Alpha.Opacity > max)
23
{
24
clearInterval(obj.changing);
25
obj.changing=false;
26
obj.filters.Alpha.Opacity = max;
27
}
28
else
29
obj.filters.Alpha.Opacity += number;
30
test1.innerText = "img1:"+img1.filters.Alpha.Opacity;
31
test2.innerText = "img2:"+img2.filters.Alpha.Opacity;
32
}
33
function sub(obj)
34
{
35
if(obj.filters.Alpha.Opacity < min)
36
{
37
clearInterval(obj.changing);
38
obj.changing=false;
39
obj.filters.Alpha.Opacity = min;
40
}
41
else
42
obj.filters.Alpha.Opacity += -number;
43
test1.innerText = "img1:"+img1.filters.Alpha.Opacity;
44
test2.innerText = "img2:"+img2.filters.Alpha.Opacity;
45
}
46
</script>
47
</head>
48
<body>
49
<img id='img1' src="bt_search.gif" style="filter:Alpha(Opacity=10)" onmouseover="OnMouseOver(this)" onmouseout="OnMouseOut
50
51
(this)">
52
<img id='img2' src="bt_search.gif" style="filter:Alpha(Opacity=10)" onmouseover="OnMouseOver(this)" onmouseout="OnMouseOut
53
54
(this)">
55
<div id='test1'>img1:10</div>
56
<div id='test2'>img2:10</div>
57
</body>
58
</html>

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

57

58
