Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <cfscript>
- // Create an instance of the mail object
- mail=new mail();
- // Set it's properties
- mail.setSubject( "Sample Email" );
- mail.setTo( "to@example.com" );
- mail.setFrom( "from@example.com" );
- mail.setCC( "cc@example.com" );
- mail.setBCC( "bcc@example.com" );
- // Add an attachment
- mail.addParam( file="C:\foo.txt" );
- // Add email body content in text and HTML formats
- mail.addPart( type="text", charset="utf-8", wraptext="72", body="This is a test message." );
- mail.addPart( type="html", charset="utf-8", body="<p>This is a test message.</p>" );
- // Send the email
- mail.send();
- </cfscript>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement