SQL PHP HTML ASP JavaScript articles and free scripts to download

Checkdnssrr function in PHP

We can check our DNS record to verify the existence of a domain name or not. We can see if plus2net.com is there in DNS record by using checkdnsrr function. This function returns True if available and returns False if not available.

The type can be A, MX, NS, PTR,SOA, AAAA, CNAME, SRV,A6 NAPTR, TXT or ANY

This function may not work properly in Windows platform ( Older than PHP 5.3 ).

Here is the simple code to check DNS records.

$domain="plus2net.com";
if(!checkdnsrr($domain,'MX')) {
echo "Not there ";
}else {
echo " It is there "; }


Google+
Post Comment This is for short comments only. Use the forum for more discussions.
Name
Email( not to be displayed)Privacy Policy
1+2=This is to prevent automatic submission by spammers. Please enter the result of the sum as asked



Join Our Email List
Email:  
For Email Newsletters you can trust
HTML . MySQL. PHP. JavaScript. ASP. Photoshop. Articles. FORUM Contact us

©2000-2014 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer