Back to Top

Check Email address using Network Functions

Check Email address using Network Functions

Today we are going back to basics of PHP with a quick tutorial on how to check email address using network functions of PHP.Network functions are the core part of PHP and most of are not using this functions so most of from us are not aware of those function which are very useful.

Here,I am going to show one function which check email address valid or not using a network function.This something interesting right?

So, let’s understand the function and how we can use network functions.First of all ,it checks if the email address format is correct, then looks up and prints the mx records.

For example, if user enter testttttt.com, and the domain does not exist, getmxrr() returns falses and the returned mxhosts array is empty

In the function,I have used checkdnsrr function which Check DNS records corresponding to a provided Internet host name or IP address.

Functions to check Email Address

You just need to call the function and you can do changes in function as per your requirement.

A big thank you for reading and feel free to share your thoughts! Don’t Forget to Follow us on Twitter or Subscribe us to Get the Latest Updates.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Most Popular Posts

How to Fetch Twitter data using cURL

Posted on 11 years ago

Bhumi