PHP Sent E-MAIL From PHP - Code

PHP Get Data from Radio Buttons Previous Next PHP Basic Errors

PHP allows you to send e-mails directly from a scirpt with the mail() Function.



Note:For the mail functions to be available, PHP requires an installed and working email system

The program to be used to defined by the configuration settings in the php.ini file.

The following code sends an email to the php script using the mail()

Filename: php / php-email.php

$from = "[email protected]";
$to = "[email protected]";
$subject = "Hello from Doe";
$message = "Hello Read for  tomorrow's match?";
$headers = "From:".$from;
echo "Mail Sent to".$to;

Running Step.

Type Url - https://localhost/php/php-email.php

Tags: PHP Sent E-MAIL From PHP PHP Code Programming Language

Was this helpful ?