0
私は2つのSVGファイルを持っています。 rect.svgの内容をtst_use.svgにxlinkしようとしています。 tst_use.svgの内容は、SVG Xlinkはxlink:hrefで外部ファイルにリンクしません<use>タグ
<svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xhtml="http://www.w3.org/1999/xhtml" version="1.1" id="svg_hom_img" width="508" height="438">
<use x="0" y="0" id="us_g1_0" width="508" height="438" xlink:href="rect.svg"/>
</svg>
あるとrect.svgの内容は、もちろん
<svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xhtml="http://www.w3.org/1999/xhtml" version="1.1" id="svg_hom_img" width="508" height="438">
<rect x="0" y="1" width="250" height="250" id="BackDrop" pointer-events="all" style="opacity:1;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:2; stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0"/>
</svg>
あり、2つのファイルが同じディレクトリにあります。私はいくつかの組み合わせを試みました。コードはインラインで動作します。 rect.svgがブラウザに表示されます。私はまた、JavaScriptを一緒にファイルをcobbleすることができます。他の人はこの構文を使用します。 tst_use.svgがrect.svgにxlinkできないのはなぜですか?ロバートLongsonさんのコメントを使用して
+0