.htaccess 背景消失。htaccess
我刚刚完成了我的.htaccess 背景消失。htaccess,.htaccess,background,styles,.htaccess,Background,Styles,我刚刚完成了我的.htaccess文件,只是重写到了一个更好的URL,但是没有理由背景消失了。如果我使用丑陋的旧URL访问,背景就在那里 <html... ... <style type='text/css'> body { color:#FFF;background:#444 url(office_1.png); } body { margin:0;padding:0; } </style> </head> .htaccess规则正在运行,但为什么我
.htaccess
文件,只是重写到了一个更好的URL,但是没有理由背景消失了。如果我使用丑陋的旧URL访问,背景就在那里
<html...
...
<style type='text/css'>
body { color:#FFF;background:#444 url(office_1.png); }
body { margin:0;padding:0; }
</style>
</head>
.htaccess
规则正在运行,但为什么我的背景消失了?URI是相对的,因此它正在查找中的图像
/your/nice/uri/office_1.png
不在
/office_1.png
通常的修复方法是使用/启动映像路径,正如我在上面的示例中所做的那样,使其相对于站点的根
url(/office_1.png);
url(/office_1.png);