2011-02-04 33 views

回答

4

这里有一个良好的开端:

<div style="position: fixed; bottom: 0; background-color: #ccc;">Hello</div> 
+0

这很有帮助,但我知道如何使一个像我想要一个像onmouseover transperency等。 – Will 2011-02-04 01:38:29

1

这是你会用,如果你添加的第一个答案在评论的链接要启动的一个例子。

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

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

<head> 
    <title>Hello!</title> 
</head> 

<style> 
#TransparentDiv{ 
    position:fixed; 
    bottom:0; 
    background: #ccc; 
    filter:alpha(opacity=50); 
    -moz-opacity:0.5; 
    -khtml-opacity: 0.5; 
    opacity: 0.5; 
} 

#TransparentDiv:hover{ 
    filter:alpha(opacity=100); 
    -moz-opacity:1; 
    -khtml-opacity: 1; 
    opacity: 1; 
} 
</style> 

<body> 

<div id="TransparentDiv">Hello World - Some more text to make this easier to read.</div> 

</body> 

</html>