Don I am not a 'PHP guru' and I dont know where you can find an algorithm but:-
If the only problem is users adding/not using name extensions, then for your company exists already test you could remove known extensions from the input company name - ltd, plc, etc - and replace this with a wildcard for the check. eg. SELECT id FROM table WHERE name LIKE '$input_name_without_extensions%' Debbie ----- Original Message ----- From: "DonPro" <[EMAIL PROTECTED]> To: "php list" <[EMAIL PROTECTED]> Sent: Wednesday, October 02, 2002 4:27 PM Subject: [PHP] How can I check for variances in spelling within form text input fields? > Hi, > > I would like some ideas on how to perform the following. Any input from the > PHP gurus would be appreciated. > > I have a form where my customer feels out certain information. Part of this > information is the company name, address, city and state/province of their > customer. I have to assign a unique number to their customer based on the > information they typed in. > > Here is my problem: > > 1) They may enter the same customer twice but have a slightly different > spelling (maybe adding a LTD. to the company name) > 2) Two of my customers may have the same customer. They will type it into my > form but again with variant spelling. > > I would like to know if there is an algorithm which allows me to check for > small variances in spelling so that I would know if this customer has > already been assigned my unique number and therefore not assign a duplicate > number. > > Thanks, > Don > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php