【发布时间】:2013-12-18 06:29:28
【问题描述】:
我在我的 HTML(text/html) 中添加了一个模糊效果 svg:
<html>
<head>...</head>
<body>
...
<svg xmlns="http://www.w3.org/2000/svg" height="0">
<filter height="116%" width="116%" y="-8%" x="-8%" id="svgBlur">
<feGaussianBlur stdDeviation="8" in="SourceGraphic"/>
</filter>
</svg>
</body>
</html>
我在我的 CSS 表中引用的内容:
#page-container {
filter: url("#svgBlur");
-webkit-filter: blur(8px);
}
这样做会使#page-container 显示为白色(FF 无法识别 SVG 过滤器)。
时髦的部分:
当我在 Firebug 中禁用上述过滤规则并在#page-container 的样式属性中读取它时,它就像一个魅力。
<div id="page-container" style="filter: url("#svgBlur");">
我在监督什么?
响应标头:
Cache-Control no-cache, must-revalidate, post-check=0, pre-check=0
Connection Keep-Alive
Content-Encoding gzip
Content-Language nl
Content-Length 6098
Content-Type text/html; charset=utf-8
Date Mon, 02 Dec 2013 14:47:01 GMT
Etag "1385995621"
Expires Sun, 19 Nov 1978 05:00:00 GMT
Keep-Alive timeout=15, max=100
Last-Modified Mon, 02 Dec 2013 14:47:01 +0000
Link </nl/node/215271>; rel="canonical",</nl/node/215271>; rel="shortlink"
Server Apache/2.2.3 (Red Hat)
Vary Accept-Encoding
X-Powered-By PHP/5.3.19
Problem on Firefox 25 OSX. Webkit browsers work fine, because they use the css blur filter
【问题讨论】:
标签: html css firefox svg svg-filters