<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=gb2312" /><title>圖片透明效果</title><style type="text/css">#wrap{? ? ? width:400px; ?height:240px; ?background:url(圖片/xuan5.jpg) no-repeat; ?margin:0 auto; ?}#word{? ? ? width:300px; ?height:200px; ?margin:20px 50px; ?background:#FFFFFF; ? ?/* for IE */? ? ? filter:alpha(opacity=40);? ? ? /* CSS3 standard */? ? ? opacity:0.4; ?}p{? ? font-family:"新宋體"; font-size:24px; line-height:50px; text-align:center; }? ?</style></head><body><div id="wrap">? ? ?<div id="word"> ? ?<p>醉夢半生<br /> ? 一朝邂逅<br /> 為你<br /> ? 寫盡紅塵 </p> </div></div></body></html>在Dreamweaver中,內部div塊可以居中顯示,但在瀏覽器中內部div塊卻是緊貼著父元素上邊界,,,為什么?
- 3 回答
- 0 關注
- 1837 瀏覽
相關問題推薦
添加回答
舉報
0/150
提交
取消