If it matters, I'm not using any javascript insertion.
And here is an actual code example from the tests I made: one using html and html 5 docytype; one using xml with xhtml and svg namespaces.
The html fails in Opera (of course), but work in Firefox 4 nightly.
BTW, thanks for all the replies. The situation does make sense ... and I can understand some browsers not implementing it yet.
I just figured I'd provide this one last example so it was perfectly clear what I meant. -- although there's not much else to discuss about it. :)
Kevin
> To: kevinar18@hotmail.com
> CC: www-svg@w3.org
> Date: Fri, 3 Sep 2010 10:44:39 +0200
> From: ed@opera.com
> Subject: Re: Should svg work in less strict html5 documents with an html mime-type?
>
> On Fri, 03 Sep 2010 04:55:38 +0200, Kevin Ar18 <kevinar18@hotmail.com>
> wrote:
>
> >
> >> On 9/2/10 8:21 PM, Kevin Ar18 wrote:
> >> > I've noticed that when inserting svg into an html 5 document !DOCTYPE
> >> > HTML that svg will not work.
> >>
> >> Inserted how? And tested how?
> > I was running in Opera. It wouldn't work in regular html like so:
> > The basic layout:
> > file.html
> > <!DOCTYPE HTML>
> > <html>
> > <body>
> > <svg>
> > <rect>
> > I wanted to see if I was misunderstanding the spec or it was a bug/lack
> > of support in the browser.
>
> I would expect that to work in Opera as soon as the full HTML5 parser is
> added, however that has not yet been included in public builds.
> Note: elm.innerHTML in current Opera builds isn't capable of inserting svg
> elements in the proper namespace.
>
> I'm guessing that's how you inserted the svg content. Standard DOM 3 Core
> methods should work just fine for inserting and creating svg elements in
> all the browsers, including Opera.
>
> Besides, if you need inline svg content to work in existing browsers then
> you'll likely need some hacks anyway, e.g script element wrappers, or
> serving as XHTML/SVG.
>
> Cheers
> /Erik
>
> --
> Erik Dahlstrom, Core Technology Developer, Opera Software
> Co-Chair, W3C SVG Working Group
> Personal blog: http://my.opera.com/macdev_ed
>