regex
-
need help with a regex that would split a given fullname to its corresponding first name, last name, middle initial im trying to emulate outlook's way of breaking down the full name to its corresponding fields. any regex or class to do this? help is highly appreciated.
Life - Dreams = Job TheCardinal BenPOS Systems
-
need help with a regex that would split a given fullname to its corresponding first name, last name, middle initial im trying to emulate outlook's way of breaking down the full name to its corresponding fields. any regex or class to do this? help is highly appreciated.
Life - Dreams = Job TheCardinal BenPOS Systems
-
If you have name as "FirstName MiddleName LastName", just split it over space. Not sure how will you manage in case first name itself contains space.
It's not necessary to be so stupid, either, but people manage it. - Christian Graus, 2009 AD
thanks, that's what i did :D but the one you've pointed out thats where my problems begin :D i just really need a regex or something to really isolate what i want to be extracted and it would not matter if the user enters some of this format's. lastname, firstname mi. firstname 2ndname mi. lastname i really wanted to have a result just like how outlook used a single textbox for fullname, and breaks it down to its specific fields. i dont like to implement IF's and Switch's, i think there a better solution in splitting or extracting the fields
Life - Dreams = Job TheCardinal BenPOS Systems
-
thanks, that's what i did :D but the one you've pointed out thats where my problems begin :D i just really need a regex or something to really isolate what i want to be extracted and it would not matter if the user enters some of this format's. lastname, firstname mi. firstname 2ndname mi. lastname i really wanted to have a result just like how outlook used a single textbox for fullname, and breaks it down to its specific fields. i dont like to implement IF's and Switch's, i think there a better solution in splitting or extracting the fields
Life - Dreams = Job TheCardinal BenPOS Systems
I think a regex is going to be horribly complex, and even then won't work everywhere: France: M. Pierre De Gaul US: Dr M Jones Japan: Surname first? Ireland: Shaemus O'Connor
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced. This message is made of fully recyclable Zeros and Ones
-
thanks, that's what i did :D but the one you've pointed out thats where my problems begin :D i just really need a regex or something to really isolate what i want to be extracted and it would not matter if the user enters some of this format's. lastname, firstname mi. firstname 2ndname mi. lastname i really wanted to have a result just like how outlook used a single textbox for fullname, and breaks it down to its specific fields. i dont like to implement IF's and Switch's, i think there a better solution in splitting or extracting the fields
Life - Dreams = Job TheCardinal BenPOS Systems
-
Even that will not help. If first name can have a space, why can't middle name have one? Or even the last name?
It's not necessary to be so stupid, either, but people manage it. - Christian Graus, 2009 AD
so whats the best way then? maybe i will just use 3 textbox separating the 3 fields and labeling then with the proper labels :D hopefully there could be a better solutions for this.
Life - Dreams = Job TheCardinal BenPOS Systems