Name

checkdnsrr

Synopsis

int checkdnsrr(string host[, string type])

Searches DNS records for a host having the given type. Returns true if any records are found, and false if none are found. The host type can take any of the following values (if no value is specified, MX is the default):

A

IP address

MX (default)

Mail exchanger

NS

Name server

SOA

Start of authority

PTR

Pointer to information

CNAME

Canonical name

ANY

Any of the above

Get Programming PHP, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.