Make IE 10 repeat svg background

2019-02-24 17:48发布

I have an svg that I'm applying as the background to the body. I'm using x-repeat, and it works in chrome and FF but in ie10 (actually ie11 beta) the background is squished and has giant bars in between each x-repeat

the link is here http://knowledgecity.com/hrtools/workstyle/svgtest.php

The syle I'm using on the body is

<body style="margin:0em;background-image: url(background-opt.svg);background-size: 1339em 1000em;background-repeat:repeat-x;overflow:hidden">  

What part of this style doesn't work in ie10? Or is it something else?

chrome: this is how it looks on chrome

IE10: This is how it looks on ie10

1条回答
手持菜刀,她持情操
2楼-- · 2019-02-24 18:44

Ok, it turns out I needed to add

preserveAspectRatio="none slice" 

to my svg element for ie to render it correctly. That solved it.

查看更多
登录 后发表回答