Ah! Do you guys know about this? Honestly I was not aware of this attribute till yesterday. It’s one of the good to have attribute for all the form tags; it helps in building security for payment related projects.
Recently I had to resolve a problem in one of the ecommerce project where user has to enter their credit card info to process the payments. The problem is the <input> tag was throwing the suggestion on the credit card number; it was retaining the credit card number & other few data even when any other user logs into the same page on the same machine.
After some googling I found the solution to the problem. It’s not exactly a problem but it’s one of the features given by the browsers to avoid entering the data on same <input> tags again and again. This is especially dangerous if someone enters their credit card number from a public computer. Hence to make sure the process is secure, use “autocomplete” attribute in your <form> tag.
<form name=”cc” autocomplete=”off” >
Our engineers out there have come up with an extra attribute called “autocomplete” which accepts the value of boolean and depending on the value it tells the browser to hide/show the pre-existing data.
Let’s secure it!