Last active
August 29, 2016 10:25
-
-
Save qinshulei/9ec29f831c04e1a21ae3a1976a3bf3d1 to your computer and use it in GitHub Desktop.
js replace select with select2
This file contains hidden or 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
| $().ready(function() { | |
| $('head').append('<script src="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.3/js/select2.min.js"></script>'); | |
| $('head').append('<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.3/css/select2.min.css">'); | |
| setTimeout(function(){ | |
| $('select').select2(); | |
| },1000); | |
| }) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment