Forum How do I...?

Embed svg into an HTML doc? --- the real post

jacobfogg
Okay, now everything got stipped out... here is the real post...

I am trying to embed SVG into normal HTML docs and am getting an error... I have tried both of the following which are valid html methods (though one is outdated):

<embed width="16" height="27" type="image/svg+xml" src="http://dj4-jacob.datajoe.com/dj4/svg.php?text=test&fontSize=15&font="/>

and

<object width="16" height="27" type="image/svg+xml" data="http://dj4-jacob.datajoe.com/dj4/svg.php?text=test&fontSize=15&font="/>

Both methods give me an error like:
joe4-jacob.datajoe.com/tmp/120040664.3318.html:192 EntityRef: expecting ';'


The svg produced by the referenced file is as follows:

<svg xmlns="http://www.w3.org/2000/svg"
	xmlns:xlink="http://www.w3.org/1999/xlink"
	version="1.1"
	baseProfile="full"
	viewBox="0 0 16 26"
	width="16px"
	height="26px">
	<text x="-26px" y="12px" fill="blue" font-family="Arial" font-size="15px" transform="rotate(270)">
		test	</text>
</svg>


Thanks!
mikeday
The ampersands in the URL (&) need to be escaped (&amp;) in HTML or XML documents.
jacobfogg
Thanks, that did the trick...