Forums

PHP

This topic is locked

Email notification of Record insert

Posted 26 May 2003 06:47:17
1
has voted
26 May 2003 06:47:17 Kent Livingston posted:
I'm looking for a simple example of generating an email to a set email address(s) upon the successful insertion of a record into a database. An extension would be nice... but an example great. Thanks -GZ

Replies

Replied 05 Oct 2004 04:14:30
05 Oct 2004 04:14:30 Kent Livingston replied:
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
I'm looking for a simple example of generating an email to a set email address(s) upon the successful insertion of a record into a database. An extension would be nice... but an example great. Thanks -GZ
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>

Is this so simple that it's unavailable... <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>
Replied 10 Oct 2004 19:52:10
10 Oct 2004 19:52:10 Dean Blackborough replied:
After the insertion code check that the query was sucessful and the just add

from the php manual

<pre id=code><font face=courier size=2 id=code>
bool mail ( string to, string subject, string message [, string additional_headers [, string additional_parameters]])
</font id=code></pre id=code>

example, from the php manual

<pre id=code><font face=courier size=2 id=code>
&lt;?php
mail(" ", "My Subject", "Line 1\nLine 2\nLine 3";
?&gt;
</font id=code></pre id=code>

Emails get sent to artists on my site after a a comment has been added to one of their images, it is very simple to do with php.

--------------------------------------
www.galleryof3d.com
(PHP and MySQL)

Edited by - G3D on 10 Oct 2004 19:53:02

Reply to this topic