This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 13853 - Add feature detection: The HTML5 specification should include a recommended feature detection technique for each major feature
Summary: Add feature detection: The HTML5 specification should include a recommended f...
Status: RESOLVED WONTFIX
Alias: None
Product: HTML WG
Classification: Unclassified
Component: HTML5 spec (show other bugs)
Version: unspecified
Hardware: Other other
: P3 normal
Target Milestone: ---
Assignee: Ian 'Hixie' Hickson
QA Contact: HTML WG Bugzilla archive list
URL: http://www.whatwg.org/specs/web-apps/...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-21 20:50 UTC by contributor
Modified: 2011-10-04 23:41 UTC (History)
7 users (show)

See Also:


Attachments

Description contributor 2011-08-21 20:50:41 UTC
Specification: http://dev.w3.org/html5/spec/Overview.html
Multipage: http://www.whatwg.org/C#top
Complete: http://www.whatwg.org/c#top

Comment:
Add feature detection:
The HTML5 specification should include a recommended feature detection
technique for each major feature.
For instance in the drag & drop section, include a recommendation on how to
detect if the Web browser implements the key features (e.g. file drop).
This is not trivial, and not standard yet.
For instance, Firefox returns false to: { 'ondrop' in
document.createElement('div') } although 'ondrop' is implemented.
A starting point:
- http://diveintohtml5.org/everything.html
- http://www.modernizr.com
- https://github.com/Modernizr/Modernizr/wiki/Undetectables
-
http://blogs.msdn.com/b/ie/archive/2010/04/14/same-markup-writing-cross-browse
r-code.aspx
-
https://developer.mozilla.org/En/Browser_Detection_and_Cross_Browser_Support#U
se_feature_oriented_object_detection
Cordially,
Alexandre Alapetite
http://alexandre.alapetite.fr


Posted from: 89.150.138.175
User agent: Opera/9.80 (Windows NT 6.1; U; fr) Presto/2.9.168 Version/11.50
Comment 1 Ms2ger 2011-08-22 12:05:14 UTC
(In reply to comment #0)
> For instance, Firefox returns false to: { 'ondrop' in
> document.createElement('div') } although 'ondrop' is implemented.

I expect this to be fixed for Firefox 9 or 10.
Comment 2 Ian 'Hixie' Hickson 2011-08-22 18:23:02 UTC
There's a "demos" field in the boxes where people can put demos showing how to do this. In general I'm reluctant to give an "official" way in the spec because each browser might have different subtleties, and the implemented reality and the specced convergence goal might not be quite in sync, etc. However, if anyone would like to offer a Web service that a script could ping and display information inline, I'd be happy to do that. That's what the status boxes do, for example: they ping a service which returns information about each section and then the boxes are generated from that.
Comment 3 Ian 'Hixie' Hickson 2011-10-04 23:41:54 UTC
EDITOR'S RESPONSE: This is an Editor's Response to your comment. If you are satisfied with this response, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:
   http://dev.w3.org/html5/decision-policy/decision-policy.html

Status: Rejected
Change Description: no spec change
Rationale: see comment 2