문제

Actually I want to make a TagClouder. Thats why I have to use 'svg' tag. When I run below code then it shows nothing on the browser but if I open the 'Inspect element' then it shows that the value of '#set_texts' is 'Tag Cloud'. If I use div without using 'g' tag then its shows output in the browser but if I use 'g' tag then it shows nothing on the browser. How can I get it?

HTML :

<svg width="960" height="600">
    <g transform="translate(480,300)" id="set_texts">
    </g>
</svg>

JQuery :

$('#set_texts').text("Tag Cloud");
도움이 되었습니까?

해결책

If you use a <text> tag , it should work:

<svg width="960" height="600">
    <text transform="translate(480,300)" id="set_texts">
    </text>
</svg>
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top