W3C home > Mailing lists > Public > www-svg@w3.org > August 2000

Re: XML to SVG... more info (A working version)

From: <AndrewWatt2001@aol.com>
Date: Thu, 24 Aug 2000 14:31:24 EDT
Message-ID: <bc.9844a95.26d6c3fc@aol.com>
To: www-svg@w3.org
In a message dated 24/08/00 19:04:30 GMT Daylight Time, 
Libo.Torres@primark.com writes:


<< 
    Can I insert a SVG image in an HTML page dinamically? I mean without
make the conversion in the server, doing it in the client using javascript >>

Libo,

Is it possible to insert an SVG image into HTML?

Yes, absolutely. You don't need JavaScript to insert an SVG image, you can 
use the <object> element in HTML.

This will display the SVG output I posted previously (assuming you name the 
file as svgtest.svg and have it in the same directory as this HTML file:


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>Untitled</TITLE>
</HEAD>
<BODY>
The SVG file should appear here:<br />
<object data="svgtest.svg" height="501" width="501" type="image/svg">
</object>
</BODY>
</HTML>

That works for me. I hope that will get you started.

Andrew Watt
Received on Thursday, 24 August 2000 14:31:58 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 5 November 2012 23:52:48 GMT