Hi there....
I need help with a regex, I need a regex to check if the qualification types are valid, e.g. Bachelor's degree, Honours degree, National Diploma, B.Tech(BACHELOR OF TECHNOLOGY), etc...
I have to check if the user's qualification matches the reqiured qualification. I have:
if($user_qualification == $required_qualification){
//do something
}
but the problem with this is that, the user might have:BACHELOR OF TECHNOLOGY
and in the requrements it has:B.Tech
. can I use a regex to make sure that even though the qualifications are spelled differently it still picks it up as the same? maybe something like:
if(preg_match($pattern, $user_qualification) == preg_match($pattern, $required_qualification)){
//do something
}
?
I get both qualification types(user and required) from database.
I have an idea of how regex works(only read a basic tut today).
a point in the right direction would be much apreciated.