Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>To add to the above example, (in case you don't know PHP very well), you just have to build the "email" using the variables: to, subject, message, and headers</p> <p>Let me know if you want to know how to create a form to fill and run this PHP script, otherwise, you can simply enter everything in this file manually, save as a PHP file, throw it up on a server that supports PHP, and navigate to the file in your browser.</p> <p><strong>Here's the code:</strong></p> <pre><code>// Setup recipients $to = 'johndoe@google.com' . ',' // comma separates multiple addresses $to .= 'janedoe@msn.com'; // subject $subject = 'PHP Email Script - Test Email'; // message (to use single quotes in the 'message' variable, supercede them with a back slash like this--&gt;&amp;nbsp; \' $message = ' &lt;html&gt; &lt;head&gt; &lt;title&gt;PHP Email Script&lt;/title&gt; &lt;/head&gt; &lt;body&gt; &lt;p style="background: #ccc; width: 100%;"&gt;Test Email Script&lt;/p&gt; &lt;/body&gt; &lt;/html&gt; '; // To send HTML mail, the Content-type header must be set $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n"; // Additional headers $headers .= 'To: Mary &lt;mary@example.com&gt;, Kelly &lt;kelly@example.com&gt;' . "\r\n"; $headers .= 'From: Birthday Reminder &lt;birthday@example.com&gt;' . "\r\n"; $headers .= 'Cc: birthdayarchive@example.com' . "\r\n"; $headers .= 'Bcc: birthdaycheck@example.com' . "\r\n"; // Send the email mail($to, $subject, $message, $headers); </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload