« Return to Thread: Save an SVG file from Javascript

Save an SVG file from Javascript

by Flavia :: Rate this Message:

Reply to Author | View in Thread

Hi! :)
I've a little problem 'cause I cannot find the exact method to save a SVG file generated dinamically.
In practise, I've a SVG document called "Map.svg" with some lines drawn on it, a document "Map.html" where I've displayed my file SVG and some Javascript function that enable me to create dinamically SVG elements, set attributes and so on ( I use DOM method like createElement, setAttribute, appendChild, getElementById....), reading direclty from a database. The results is a more complex SVG displayed perfectly on my web page.
But how can I save this complete SVG generated dinamically after I've generated all my elements in a precise location on my computer? I want to have a file, for exemple "MapComplete.svg" that is the results of all of this updatings.
Someone knows the solution?
Thank you in advance
Flavia :)

 « Return to Thread: Save an SVG file from Javascript