91-9990449935 0120-4256464 |
Node.js DNSThe Node.js DNS module contains methods to get information of given hostname. Let's see the list of commonly used DNS functions:
Node.js DNS Example 1Let's see the example of dns.lookup() function. File: dns_example1.js Open Node.js command prompt and run the following code: Node.js DNS Example 2Let's see the example of resolve4() and reverse() functions. File: dns_example2.js Open Node.js command prompt and run the following code: Node.js DNS Example 3Let's take an example to print the localhost name using lookupService() function. File: dns_example3.js Open Node.js command prompt and run the following code:
Next TopicNode.js Net
|