Using the <object> Element
The <embed> element was deprecated by the W3C in HTML 4, although, as you’ve seen in earlier examples, the element still continues to perform its function, even if you have to resort to the use of slightly unorthodox syntax to achieve zero margins cross-browser. The element now preferred by W3C for displaying SVG and other objects on an HTML or XHTML Web page is the <object> element. However, its use is fraught with practical issues and difficulties.
First, Figure 10.06 shows what happens if you use the <object> element just as you used the <embed> element for the first example.
Figure 10.06. Using the <object> element in Internet Explorer causes the loss of a little of the SVG image.
In Figure 10.06, you can see ...
Get Designing SVG Web Graphics now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.