mortalc 0 Posted March 20, 2011 Report Share Posted March 20, 2011 I don't know if this is the right place to ask about SVG, but here goes.I've created this code for a circle moving up and down in a square. But for some reason, it isn't moving. <?xml version="1.0" encoding="UTF-8" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN""http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg width="100%" height="100%" version="1.1"xmlns="http://www.w3.org/2000/svg"><rect x="0" y="0" height="500" width="500" style="stroke-width:1; stroke:black; fill:white"></rect><circle cx="250" cy="50" r="50" stroke="red" stroke-width="0" fill="red"> <animate id="down" attributeType="XML" attributeName="cy" from="50" to="450" dur="5s" begin="0s; up.end"/> <animate id="up" attributeType="XML" attributeName="cy" from="450" to="50" dur="5s" begin="down.end" /> </circle></svg> Quote Link to post Share on other sites
mortalc 0 Posted March 20, 2011 Author Report Share Posted March 20, 2011 Never Mind! I have fixed it! HUZZAH! Quote Link to post Share on other sites
mortalc 0 Posted March 20, 2011 Author Report Share Posted March 20, 2011 Ok, now a question - What would I use to create an interactive SVG?XML DOM?JavaScript?Name the name, and I'll go learn it. Quote Link to post Share on other sites
boen_robot 107 Posted March 20, 2011 Report Share Posted March 20, 2011 Both... plus a few SVGDOM functions, though they're optional (i.e. can be achieved with those other two). Quote Link to post Share on other sites
mortalc 0 Posted March 20, 2011 Author Report Share Posted March 20, 2011 Hrm... Just in case, where is the SVG DOM tutorial? Quote Link to post Share on other sites
boen_robot 107 Posted March 20, 2011 Report Share Posted March 20, 2011 There is none. But it's in the spec non the less, and most of it is implemented by most browsers.But again: The idea of those methods is to simplify stuff that you can otherwise do with JavaScript's XML DOM. Quote Link to post Share on other sites
mortalc 0 Posted March 20, 2011 Author Report Share Posted March 20, 2011 Ok! Thanks! Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.