Cfmail not working. Please help!

I am trying to get this to send an email each time a file is
uploaded. All the fields in the form are updating the database
correctly but the email is never sent and no error message is
generated. Any ideas....please help!!!
<cfif IsDefined("FORM.ID")>
<cfupdate datasource="xxxxxxx" tablename="FTPCatalog">
<cfelse>
<cfinsert datasource="xxxxxxx" tablename="FTPCatalog">
<cfmail to = "#SendTo#"
from = "#EmailAddress#"
subject = "FTP file upload notification!"
server = "mail.server.net" >
A file has been uploaded to the server.
</cfmail>
</cfif>

you do realise that your code as it is in your original post
will only
send email when a NEW RECORD is INSERTED into the db? no
email will be
sent on UPDATE of db because how your cfif/cfelse is
constructed.
Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com

Similar Messages

Maybe you are looking for

  • How do I empty all the files in the "Downloads" folder ?

    How do I empty all the files in the "Downloads" folder ? Can they all be deleted at once?

  • Enable Functional Area field in PA30 Info type 0001 Screen

    Hi, I need to enable Functional Area (PA0001-FKBER) field in info type 0001 screen of PA30 and the functional area should pick up value corresponding to cost centre. I unhide the field in T588M table, but still i dont see the field in PA30 Info type

  • Looking for awesome Flex developers

    I'm looking for awesome Flex developers who are interested in creating real-time collaborative applications. Deadline is 7 of May. You may call it a race. The apps created are automatically registered in a public voting system. The most popular app c

  • Li tag shifts my webpage left 10ish pixels

    Hi, I'm not too sure of all the information someone might need to identify my issue here but its completely stumped me. I have made a website with a header / footer / left column / main content center / right column. It uses em as the size mesurment

  • Creating Rough Cuts from an Extension in Prelude CC 2014

    I am building an extension panel using extension builder 3 for Prelude CC 2014 and want to have a button to create rough cuts from a selection of markers. After looking at the CSXS API I can see that the events which I would need to use, such as com.