checkdnsrr on WIN NT and IIS
| From: | Andy Warwick | Date: | Sat, 24 Jun 2000 23:30:50 +0000 |
| Subject: | checkdnsrr on WIN NT and IIS | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-636@lists.php.net to get a copy of this message | ||
Having a few problems with the checkdnsrr command under Windows NT and IIS.
The following code
<?php
if (checkdnsrr('creed.co.uk','ANY')) {echo "foo";}
if (gethostbyname('creed.co.uk')) {echo "bar";}
?>
only gives the result "bar"
Any variation I try of checkdnsrr doesn't seem to work.
I'm trying to use the command to validate email addresses in forms, but even
though I can get the host name, it refused to believe their is a dns entry?
Doing a normal NS lookup shows the domain in question has got MX records.
<nslookup:creed.co.uk/*/158.152.1.58>
Non-authoritative answer:
creed.co.uk NS 12954 ns1.netnames.net 212.53.64.60
creed.co.uk NS 12954 ns2.netnames.net 212.53.77.28
creed.co.uk MX 21556 10 relay1.netnames.net
creed.co.uk MX 21556 20 relay2.netnames.net
creed.co.uk SOA 21589 ns1.netnames.net
hostmaster.netnames.net
Serial 1
Refresh 10800 (3 hours)
Retry 1800 (30 minutes)
Expire 3600000 (41 days)
Minimum TTL 21600 (6 hours)
Authority:
creed.co.uk NS 12954 ns1.netnames.net
creed.co.uk NS 12954 ns2.netnames.net
NSLookup normal completion.
Any pointers as to where I'm going wrong or workarounds if its a WIN bug?
Regards
Andy W