Send mail example using the mail function
The mail function in php is built-in unlike a lot of other languages such as ASP and is extremely easy to use. Below is a simple example (copy the below into a file with a php extension such as mailtest.php and upload it to your webspace):
NB: Please ensure you have php setup for your domain, you can do this using your hosting control panel under domain menu > website settings > ticking the php checkbox and clicking save
PHP, MySQL, Joomla, Wordpress and other CMSes as well as CSS, jScript, jQuery related tested & trusted references links will be posted here for every PHP enthusiasts references. Enjoy
Search This Blog
Showing posts with label function. Show all posts
Showing posts with label function. Show all posts
Sunday, August 3, 2008
E-mail Validation with PHP
E-mail Validation with PHPWhen you register on at a website, the site normally checks if the e-mail address that you enter is in a valid format. This is done by using what called a Regular Expression. What we need to do is check if a string (eg $email) matches the regular expression:
Subscribe to:
Posts (Atom)