Created
October 14, 2013 07:43
-
-
Save NOEinteractive/6972206 to your computer and use it in GitHub Desktop.
Placeholder polyfill with yepnope
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//si le browser ne supporte pas l'attribut placeholder, | |
//ce JS va charger un polyfill et l'appliquer sur tous les inputs de la page | |
//https://github.com/mathiasbynens/jquery-placeholder | |
yepnope({ | |
test:'placeholder' in document.createElement('input'), | |
nope: namespace.themeUrl+'/js/libs/jquery.placeholder.js', | |
callback: function(url, result, key) { | |
$.fn.placeholder && $('input').placeholder(); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment