具体参考:https://github.com/jondavidjohn/payform
插件js: jquery.payform.js
具体操作
alert($.payform.validateCardNumber('4242424242424242'));//true
alert($.payform.parseCardType('4242424242424242'));//visa / Visa
alert($.payform.parseCardType('6042708104454470'));//discover / Discover
alert($.payform.parseCardType('5265541846020487'));//mastercard / Master
alert($.payform.parseCardType('3412121212121212'));//amex / Express