Dear all,

We shouldn't really have to check for the existence of methods, etc. An HTML
DOM that can have SVG inline should really return true for one of:

  document.implementation.hasFeature("org.w3c.dom.svg", "1.0")

or:

 
document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#SVG";,
"1.1")

I haven't tried it, but I would say that's what Opera and Mozilla _should_
provide (and may well do).

Regards,

Mark



Mark Birbeck
CEO
x-port.net Ltd.

e: [EMAIL PROTECTED]
t: +44 (0) 20 7689 9232
w: http://www.formsPlayer.com/
b: http://internet-apps.blogspot.com/

Download our XForms processor from
http://www.formsPlayer.com/ 

> -----Original Message-----
> From: [email protected] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Holger Will
> Sent: 28 July 2005 19:38
> To: [email protected]
> Subject: Re: [svg-developers] Re: Detect native SVG support
> 
> Holger Will schrieb:
> 
> > Jonathan Watt schrieb:
> >
> > > First off, I've noticed that my suggested script doesn't 
> work in IE6 
> > > since it doesn't seem to implement createElementNS. To prevent a 
> > > script error I'll revise my script to:
> > >
> > > var hasNativeSVG = false;
> > > try {
> > >   if
> > > 
> (document.createElementNS('http://www.w3.org/2000/svg','svg').width)
> > <http://www.w3.org/2000/svg%27,%27svg%27%29.width%29>
> > > <http://www.w3.org/2000/svg%27,%27svg%27%29.width%29>
> > >     hasNativeSVG = true;
> > > } catch (e) { /* ignore exception */ };
> > >
> > >
> > > On 7/28/05, Holger Will <[EMAIL PROTECTED]> wrote:
> > > > Hi Jonathan,
> > > >
> > > > in most cases i tend to favor the "<object>alternate
> > content</object>" -
> > > > syntax, which works without script.
> > >
> > > Yup, but John asked for a script, so that's what I was 
> trying to do.
> > > Also the <object> approach will not differentiate between plug-in 
> > > and native support.
> >
> > i should have statet that this is a bit off topic. your 
> script seems 
> > like a very clean and easy solution !
> >
> > >
> > > > i've tried the following without success, and i wonder if the 
> > > > behavior is specified like this or if its a bug.
> > > > <object ... >
> > > > <img ... onload="alert('SVG not supported')/> </object>
> > >
> > > I thought you were trying not to rely on script support. j/k ;-)
> >
> > i still do :-) i was just wondering ...
> >
> > >
> > > > THIS DOES NOT WORK !
> > > > the onload allways gets fired. is this right? do html clients 
> > > > allways load both the objects content and the alternate 
> content ?
> > > > is there another event that can be used ? is there any other 
> > > > specified way to determin if object renders the 
> original content 
> > > > or the
> > alternate
> > > > content ?
> > >
> > > Hmm, I'm not sure. That the onload get's evaluated seems 
> like a bug
> > to me.
> >
> > yeah it seems strange but at least mozilla, opera and ie 
> agree on the 
> > behaviour :-) so even if mozilla would get this right, it 
> would be as 
> > useless as contentDocument for cross browser detection of 
> svg support.
> >
> > thanks for your comments anyways
> > Holger
> >
> i dont know what ive tested last time, but this indeed seems 
> to work in IE and Opera, so this is probably  a bug in 
> mozilla, in which component would i post this bug ?
> 
> Holger
> 
> 
> 
> 
> -----
> To unsubscribe send a message to: 
> [EMAIL PROTECTED]
> -or-
> visit http://groups.yahoo.com/group/svg-developers and click 
> "edit my membership"
> ----
> Yahoo! Groups Links
> 
> 
> 
>  
> 
> 
> 
> 





-----
To unsubscribe send a message to: [EMAIL PROTECTED]
-or-
visit http://groups.yahoo.com/group/svg-developers and click "edit my 
membership"
---- 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/svg-developers/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to