Jump to content

Data validation


takeiteasy

Recommended Posts

Hi all, can i ask if there's a code for data validation like for example,
i have this
[code]Amt. Paid: SG$  <input type = 'text' name='amtpaid' size='10' maxlength='10'>[/code]
and in my database, the type is Varchar(10).

Currently, it can store any kinds of character, but what i wanted is only numbers and decimals to be stored into the database.
So is there any code or way that the system will check if it is only numbers and decimals den it can be added to the database, if not a prompt to inform the user that only numbers can be proceed.

TIA!
Link to comment
https://forums.phpfreaks.com/topic/13515-data-validation/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.