I\'m trying to replace an SVG image embedded in IMG tag with the content of this SVG and output it inline. In other words lo load the contents of SVG file of given IMG SRC a
You cannot load data via ajax using the file:// protocol. You need to use http://
file://
http://
For example, move the svg file to the same folder as your javascript file and then do:
$.get('img01.svg', function(data) { $bg.append(data); });