用户登录
用户注册

分享至

svg元素图

  • 作者: 晨稳1
  • 来源: 51数据库
  • 2020-10-02
&lt;html&gt;<br>&lt;head&gt;<br>&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot;&gt;<br>&lt;title&gt;Insert title here&lt;/title&gt;<br>&lt;script type=&quot;text/javascript&quot;&gt;<br>    function load() {<br>        var embedTag = document.createElement('embed');<br>        embedTag.type = &quot;image/svg+xml&quot;;<br>        embedTag.width = &quot;640&quot;;<br>        embedTag.height = &quot;480&quot;;<br>        embedTag.onload = function() {<br>            alert(embedTag.getSVGDocument());<br>        };<br>        embedTag.src = &quot;test.svg&quot;;<br>        document.body.appendChild(embedTag);<br>    }<br>&lt;/script&gt;<br>&lt;/head&gt;<br>&lt;body onload=&quot;load();&quot;&gt;<br>&lt;/body&gt;<br>&lt;/html&gt;
软件
前端设计
程序设计
Java相关