Skip to content

Instantly share code, notes, and snippets.

@milesplit
Forked from miketaylr/formsuitest.js
Created November 28, 2011 07:41
Show Gist options
  • Save milesplit/1399503 to your computer and use it in GitHub Desktop.
Save milesplit/1399503 to your computer and use it in GitHub Desktop.
testSupport
// testSupport for HTML 5 input types
// By: Jason Byrne of MileSplit, Inc.
//
// Just needed a simple thing to test for support
//
// Adapted from: http://miketaylr.com/code/html5-forms-ui-support.html
var testSupport = function(t){
var f = ':(';
return ($('<input type="' + t + '">').val(f).val() !== f);
};
@milesplit
Copy link
Author

I only tested this with input color so far

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment