Would there be anyway to merge the below queries into a single function? As it stands only the second Strpos function works. If i remove the second one then the first one will work. I need to run both as I have to check for 2 separate strings.
$check1 = QueryWhoisServer($whoisserver, $domain);
if(strpos($check1,"No match for") !== FALSE){
return "Result Example";
}
$check2 = QueryWhoisServer($whoisserver, $domain);
if(strpos($check2,"No Data Found") !== FALSE){
return "Result 2 example";
}
else {
Any help would be much appreciated.
First of all, you should keep the output of your whois query.
Then, you can run multiple searches: