我可以在javascript中使用SVG文本标签。但它不起作用。这些是我的Javascript代码。如何在javascript中使用svg文本标签
O=evt.target;
Doc=O.ownerDocument;
L = Doc.createElementNS(xmlns, "text");
L.setAttribute("x", 10);
L.setAttribute("y", 10);
L.node.textContent("abcdef");
L.setAttribute("fill", "red");
O.appendChild(L);
SVG的文本标签,例如:
<text x="10" y="10" fill="red">abcdef</text>
什么在我的javascript代码类型的错误。 问候,VIJI
xmlns是什么意思? – 2012-08-06 11:46:29
xmlns =“http://www.w3.org/2000/svg”它是我的xmlns。 – Viji 2012-08-06 12:17:32