2010-08-25 30 views

回答

10

使用CSS来指定您的背景图片(background已被弃用)并关闭重复。

把这个在您的head部分:

<style type="text/css"> 
body 
{ 
    background-image: url(images/bg_wide.gif); 
    background-repeat: no-repeat; 
} 
</style> 

还有定位的背景图像(background-position)的属性。

more on defining backgrounds at w3schools

+0

谢谢!解决方案是 background-repeat:repeat-x – Ronny 2010-08-25 15:06:54

2

您可以使用这种风格,并保持图像的重复:

body { 
    background:url(images/bg_wide.gif) no-repeat; 
} 

no-repeat将保持图像的重复。