PHP Script to send Email
Now a days PHP is most commonly used language for developing web applications and is also flexible, as it provides several features that reduces the human efforts and several programs can be made in PHP that would be responsive and will work automatically whenever required. Today, we will discuss about similar PHP applcation that is PHP Script to send email.
Now a days PHP is most commonly used language for developing web applications and is also flexible, as it provides several features that reduces the human efforts and several programs can be made in PHP that would be responsive and will work automatically whenever required. Today, we will discuss about similar PHP applcation that is PHP Script to send email.
PHP Script to send email
There is a simple built in function in PHP for sending mails that is mail() function, this PHP function allows us to send mail to anyone on the internet.
PHP mail() Function
Here you will learn sending simple mail using PHP mail() function
Syntax of PHP mail() function
Here is the syntax of PHP mail() Function
- To : Here you have to specify the Receivers email
- Subject : Here subject of the email is specified.
- message : In this part comes the main message which to want to mail to anyone.
- header : It is optional part that can be used for specifying additional headers like cc, bcc from etc
- parameters : It is optional and can be used for specifying some additional parameters to send mail program
NOTE - Minimum version of PHP 4 is required for using mail() function.
