jQuery: How to innerHTML an HTML tag without id?
- by marknt15
Hi,
For example I have this HTML code:
<div id="canvas">
<div id="root">
<div id="content">
<span>
<title>My SVG Example Title</title>
<ellipse id="svg_1" />
</span>
</div>
</div>
</div>
How can I innerHTML the <span> tag without changing the <title> tag using jQuery?
So my expected output would be something like this:
<div id="canvas">
<div id="root">
<div id="content">
<span>
<title>My SVG Example Title</title>
<input type="text" value="this is the innerHTML I must insert but how?" />
</span>
</div>
</div>
</div>