Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

HTML5 introduces a wide variety of tools such as Geolocation. Many browsers support them, but some do not yet.

Should web developers rely on them to build professional applications for industry? The features are powerful, but not all browsers support these features.

What are some ways (perhaps Javascript libraries?) to reliably test for browser support for HTML5 features such as Geolocation?

share|improve this question
    
Why not?....... –  Robert Harvey Mar 20 '12 at 3:21
    
Because not all browsers support HTML5 features. –  David Faux Mar 20 '12 at 3:21
    
What are some ways to reliably test for browser support for HTML5 features such as Geolocation? -- One way is to write a small program using those features, and try it out in each browser you want to test. –  Robert Harvey Mar 20 '12 at 3:22
    
Yes, but is there a dynamic way, perhaps a library to do so? –  David Faux Mar 20 '12 at 3:22
    
Now we're getting somewhere. –  Robert Harvey Mar 20 '12 at 3:23
show 2 more comments

2 Answers

up vote 6 down vote accepted

Modernizr supports detection of many features in HTML5 capable browsers, including geolocation.

share|improve this answer
add comment

http://caniuse.com/ is a good reference for browser support of specific features that you can use in deciding what is possible on the browsers that you need to support.

For specific features detection script is usually fairly easy to write, but there is no indicator of overall HTML5 support.

Another way to look at it is that you can use any feature you want as long as you don't have to support IE - the one major exception is local storage, as Mozilla and Webkit don't agree on how a database should work.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.