CreateJob Method



 
The CreateJob method creates an object that permits sending emails.


Syntax

    [obj=] SiteKiosk.Email.CreateJob(usedefaults)
    
Parameters
    usedefaults Boolean value that indicates if the email account settings configured in the SiteKiosk configuration should be used (true) or not (false). Optional, default is true.
Return Value Remarks
    None.
Examples
    The following example sends an email to a specified address.

    <SCRIPT TYPE="text/javascript">
    window.external.InitScriptInterface();
    mymail = SiteKiosk.Email.CreateJob(false);
    mymail.POPServer = "mypopserver.com";
    mymail.POPPort = 110;
    mymail.Username = "myusername";
    mymail.Password = "mypassword";
    mymail.SMTPServer = "mysmtpserver.com";
    mymail.SMTPPort = 25;
    mymail.Authentication = 2;
    mymail.SetSender("me@myserver.com", "My name");
    mymail.AddRecipient("recipient@server.com");
    mymail.Subject = "This is the subject.";
    mymail.PlainBody = "This is the content.";
    mymail.Send(0, false, true);
    </SCRIPT>
    

Applies to
    SiteKiosk v5.0 (and later versions).

Back to top