SlideServe
Menu
Préférences
© SlideServe · v2026

Email Syntax in PHP for Sending Messages Effectively

jodie avatar
4 diapositives · 137 Views · Oct 04, 2014

Learn how to send emails using PHP and ensure successful delivery with proper syntax and formatting for your messages. Explore examples to understand the process better.

Email Syntax in PHP for Sending Messages Effectively - slide 1
01 / 4Email Syntax in PHP for Sending Messages Effectively
1 / 17

Télécharger la présentation

Email Syntax in PHP for Sending Messages Effectively
Une image / un lien ci-dessous est fourni (tel quel) pour télécharger la présentation

Politique de téléchargement : le contenu du site vous est fourni TEL QUEL pour votre information et votre usage personnel ; il ne peut être vendu, concédé sous licence ni partagé sur d’autres sites sans l’accord de son auteur.Le contenu vous est fourni TEL QUEL, pour votre information et votre usage personnel uniquement. Téléchargez la présentation en cliquant sur ce lien. Lors du téléchargement, si vous ne parvenez pas à télécharger une présentation, l’éditeur a peut-être supprimé le fichier de son serveur.Pendant le téléchargement, si vous ne parvenez pas à obtenir une présentation, le fichier a peut-être été supprimé par l’éditeur.

F I N

Plus de contenu associé

Transcription de la présentation
  1. Web ProgrammingWeek 9 Old Dominion University Department of Computer Science CS 418/518 Fall 2010 Martin Klein <mklein@cs.odu.edu> 10/26/10

  2. Sending E-Mail PHP syntax: mail($to, $subject, $message, $headers); e.g. <?php mail("cs518f10@gmail.com", "My status line", "If I could only think of a msg I would put it here..."); echo "congrats, your email was sent"; ?> (see firstmail.php, ch10)

  3. Sending E-Mail $to = "cs518f10@gmail.com"; $subject = "My subject line"; $message = "<h1>If I could only</h1>"; $message .= "<b>think</b>"; $message .= "<i> of a msg</i>"; $message .= "<pre> I would put it here.</pre>"; $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; $headers .= "Content-Transfer-Encoding: 7bit\r\n"; mail($to, $subject, $message, $headers); (see secondmail.php, ch10)

  4. From mklein@cs.odu.edu Mon Aug 16 09:33:57 2010 Return-Path: <mklein@cs.odu.edu> Received: from mail.cs.odu.edu (darkisland.csnet.cs.odu.edu [128.82.4.212]) by unixmail.cs.odu.edu (8.14.2/8.14.2) with ESMTP id o7GDXuSY015967 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT)for mklein@unixmail.cs.odu.edu>; Mon, 16 Aug 2010 09:33:57 -0400 (EDT) … MIME-Version: 1.0 … Subject: Email was hacked, I apologize it is fixed now. From: john doe <jdoe@gmail.com> To: Martin Klein <mklein@cs.odu.edu> Content-Type: multipart/alternative; boundary="001485f626f00069b6048df0e27f“ … --001485f626f00069b6048df0e27f Content-Type: text/plain; charset="ISO-8859-1" In case a message with a link was sent from me my email was corrupted and sent out to my inbox. I have fixed the account and apologize for the inconvenience. John -- John M. Doe --001485f626f00069b6048df0e27f Content-Type: text/html; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable <div>In case a message with a link was sent from me my email was corrupted and sent out to my inbox. I have fixed the account and apologize for the in convenience.</div> <div>=A0</div> <div>John<br clear=3D"all"><br>-- <br>John M. Doe<br></div> --001485f626f00069b6048df0e27f-- Trailing -- indicate end of msg!