Inline SVG and jQuery selection
html, javascript, jquery, svg, xhtml
Solution
This will do what you're asking...
$("#move")[0].beginElement();
Without knowing more I can't say much more than that. `jQuery()[0]` returns the DOM element, rather than the jQuery object.
Problem
I have an inline SVG in an HTML file. This SVG has an animation inside with an id "move". If I call this animation using jQuery 1.9.1 to modify its attributes, like so: ``` $("#move").attr("from", "500"); ``` it works perfectly (in Firefox 16.0.1 at least, I haven't tested other browsers). If I try to launch the animation using jQuery like this: ``` $("#move").beginElement(); ``` it doesn't work, again in Firefox. If I call it using JavaScript like this: ``` var move=document.getElementById("move"); move.beginElement(); ``` it works. How do I call the `beginElement()` function using jQuery? Thank you.