<嵌入>Firefox 3 中的 SVG 或 TIFF嵌入>
Firefox 本身就支持 SVG。但是,我有一个网页,其中 SVG 图形已ed,并且需要一个插件来显示它。
当我点击插件图标时,FF没有推荐任何插件。
提问:
- 有这样的插件吗?
- 有没有办法让 FF 使用其本机支持显示嵌入的 SVG,而无需安装插件?
TIFF 文件也会发生同样的情况。
更新:
代码:
<td align="left">
<p>
<embed
src="/file-server/review/AttachedFilesServlet.servlet?attachedFileId=28604|original=additional-docs/medicine.svg"
alt="SVG"> Image SVG
</p>
</td>
Firefox has native support for SVG. However, I have a web page where the SVG graphig is <embed>
ed, and a plugin is requested to show it.
When I click on the plugin icon, no plugin is proposed by FF.
Questions:
- Is there such a plugin?
- Is there a way to make FF display embedded SVGs using its native support without installing a plugin?
The same happens with TIFF files.
UPDATE:
Code:
<td align="left">
<p>
<embed
src="/file-server/review/AttachedFilesServlet.servlet?attachedFileId=28604|original=additional-docs/medicine.svg"
alt="SVG"> Image SVG
</p>
</td>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我最近遇到了一些问题。我设法使其工作的方法是使用嵌入函数(我最初使用html5,firefox 3.6还不支持内联svg)
使用的语法是,其中工作区仅包含SVG代码:
上面的代码不需要一个插件,我用的时候没有。使用
而不是
Adobe 曾经提供过一个插件,但他们不再提供对其的支持,因此明智的做法是不要使用它。
编辑以响应OP发布的代码:
我能想到的只有两个原因,为什么你的代码不起作用,但不确定它们是否真的会产生影响:
a)关闭嵌入标签(几乎肯定不是问题) ,但无论如何这样做都是很好的做法)。
b) 由于我看不到你的 servlet,我不能假设你没有将内容类型设置为 image/svg+。这可能是一个问题。
I've had a few issues with this recently. The way that I managed to make it work was using the embed function (I was initially using html5, which firefox 3.6 doesnt support inline svg, yet)
The syntax used was, where workspace contains just SVG code:
The above code shouldn't need a plugin, and didn't when I used it. The advantage of using
<embed>
rather than<object>
is because it allows you to run scripts. If your syntax is slightly different then that could be your issue. If your syntax is the same, post your code as a whole so we can have a look.Adobe used to supply a plugin but they no longer give support for it so it is wise not to use it.
Edit in response to code posting by OP:
There are only two reasons I can think of, as to why your code isnt working, but not sure if they would actually make a difference:
a) Closing the embed tag (almost definetly not the problem, but is good practice to do so anyway).
b) As I cant see your servlet I cant assume that you have not set the content type to be image/svg+. That could be an issue.