This app will show you how to create a simple credit card form. We'll build the whole thing from scratch,with a little help from Bootstrap 3 for the interface, and Payform.js for client-side form validation.
Keep in mind that storing credit card data on your servers is serious business. You need to be PCI compliant and fulfill a vast number of requirements. Unless you know what you're doing, it is best to use the services of a third party payment processor like Stripe or PayPal that stores all payment information for you.