--------------34B0238AF1774EA956E192C0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi Kevin,

Okay, I lied, it didn't work like a charm. ; )

Thanks for your help though.  I am actually trying to have the update and cfmail 
function occur in the same page.  I am getting it to work, well, sort of.  I am having 
trouble using
variables from the form for the to, from and cc fields. I want the user to be able to 
input the to and from fields within the form- then have cfmail send out the 
notification to those
email addresses.

I have my update form:
<form action= update.cfm . . . (with input type"text" name="email_to" . . . input 
type"text" name="email_from")  . . . </form>
and then my
<cfmail
TO=#Form.email_to#
FROM=#Form.email_from#
>
</cfmail>

It updates the database successfully, but it cannot identify the cfmail to and from 
variables.  My cfmail tag function itselfs works, because I have tested it by hard 
coding an email
address, and not using the variables, and the email notification is sent out.

Any ideas what I may be doing wrong?
Thanks for the help (again)!

Karen

Kevin Marshall wrote:

> Karen,
>
> Is there any reason that you couldn't use the CFMail tag in the same cf
> page that inserts the form fields into the data?
>
> It would look like this:
> ---user submits form---
> <cfquery...> (or cfinsert)
> Insert into...
> </cfquery>
>
> <cfmail to=#form.to# from=#form.From# cc=#form.CC#>
> this is an automatic notification that the database has been updated!
> </cfmail>
>
> I would recommend that you do the mail message after the insert (or update)
> so that if the db operation fails, the message doesn't get sent
> prematurely.  We currently do something almost exactly like this - except
> that we don't always use form variables for the from,to,...etc.
>
> hth,
> Kevin
>
> At 10:04 AM 4/13/00 -0400, you wrote:
> >Hi,
> >
> >I have a form right now that updates a database in CF.  I would like for
> >an automatic email notification to occur after the database has been
> >updated.  The "to, from and cc" fields would be included in the update
> >form.  Currently, we are using a form2email perl script for email
> >notification.  I am not familiar with CFMail.  Any ideas how this could
> >be accomplished within one form?
> >
> >Thanks!
> >Karen
>
> --------------------------
> Kevin Marshall
> Web Application Developer
> eCalton.com, Inc.
> Vero Beach, FL
> www.ecalton.com
> [EMAIL PROTECTED]
> 561.569.4500
>
> ------------------------------------------------------------------------------
> Archives: http://www.eGroups.com/list/cf-talk
> To Unsubscribe visit 
>http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
>message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

--------------34B0238AF1774EA956E192C0
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Hi Kevin,
<p>Okay, I lied, it didn't work like a charm. ; )
<p>Thanks for your help though.&nbsp; I am actually trying to have the
update and cfmail function occur in the same page.&nbsp; I am getting it
to work, well, sort of.&nbsp; I am having trouble using variables from
the form for the to, from and cc fields. I want the user to be able to
input the to and from fields within the form- then have cfmail send out
the notification to those email addresses.
<p>I have my update form:
<br>&lt;form action= update.cfm . . . (with input type"text" name="email_to"
 . . input type"text" name="email_from")&nbsp; . . . &lt;/form>
<br>and then my
<br>&lt;cfmail
<br>TO=#Form.email_to#
<br>FROM=#Form.email_from#
<br>>
<br>&lt;/cfmail>
<p>It updates the database successfully, but it cannot identify the cfmail
to and from variables.&nbsp; My cfmail tag function itselfs works, because
I have tested it by hard coding an email address, and not using the variables,
and the email notification is sent out.
<p>Any ideas what I may be doing wrong?
<br>Thanks for the help (again)!
<p>Karen
<p>Kevin Marshall wrote:
<blockquote TYPE=CITE>Karen,
<p>Is there any reason that you couldn't use the CFMail tag in the same
cf
<br>page that inserts the form fields into the data?
<p>It would look like this:
<br>---user submits form---
<br>&lt;cfquery...> (or cfinsert)
<br>Insert into...
<br>&lt;/cfquery>
<p>&lt;cfmail to=#form.to# from=#form.From# cc=#form.CC#>
<br>this is an automatic notification that the database has been updated!
<br>&lt;/cfmail>
<p>I would recommend that you do the mail message after the insert (or
update)
<br>so that if the db operation fails, the message doesn't get sent
<br>prematurely.&nbsp; We currently do something almost exactly like this
- except
<br>that we don't always use form variables for the from,to,...etc.
<p>hth,
<br>Kevin
<p>At 10:04 AM 4/13/00 -0400, you wrote:
<br>>Hi,
<br>>
<br>>I have a form right now that updates a database in CF.&nbsp; I would
like for
<br>>an automatic email notification to occur after the database has been
<br>>updated.&nbsp; The "to, from and cc" fields would be included in the
update
<br>>form.&nbsp; Currently, we are using a form2email perl script for email
<br>>notification.&nbsp; I am not familiar with CFMail.&nbsp; Any ideas
how this could
<br>>be accomplished within one form?
<br>>
<br>>Thanks!
<br>>Karen
<p>--------------------------
<br>Kevin Marshall
<br>Web Application Developer
<br>eCalton.com, Inc.
<br>Vero Beach, FL
<br>www.ecalton.com
<br>[EMAIL PROTECTED]
<br>561.569.4500
<p>------------------------------------------------------------------------------
<br>Archives: <a 
href="http://www.eGroups.com/list/cf-talk">http://www.eGroups.com/list/cf-talk</a>
<br>To Unsubscribe visit <a 
href="http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk">http://www.houseoffusion.com/index.cfm?sidebar=lists&amp;body=lists/cf_talk</a>
or send a message to [EMAIL PROTECTED] with 'unsubscribe'
in the body.</blockquote>
</html>

--------------34B0238AF1774EA956E192C0--

------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to