What are the differences between root servers, authoritative name servers, and parent servers in the context of DNS queries using PHP?

When making DNS queries using PHP, it's important to understand the differences between root servers, authoritative name servers, and parent servers. Root servers are the highest level of DNS servers that store the top-level domain information. Authoritative name servers store specific domain information and are responsible for providing answers to queries about those domains. Parent servers are servers that are one level above the authoritative name servers and help in resolving queries by directing them to the correct authoritative name server.

// Example PHP code snippet demonstrating how to query authoritative name servers using PHP
$domain = 'example.com';
$authoritative_name_server = 'ns1.example.com';

// Query the authoritative name server for the domain
$dns_records = dns_get_record($domain, DNS_NS, $authoritative_name_server);

// Print the DNS records returned by the authoritative name server
print_r($dns_records);