string
LoginName
= "spread@reasonables.com";
string
LoginPassword
= "spread";
string
CampaignName
= "Noclone
campaign";
//Define the from
infomation
string
From
= "myedm@edm.com";
string
FromName
= "Reasonable";
//Define
recipient email
string
To
= "noclone@reasonables.com";
//Define
the email subject and content
string
Subject
= "NoClone
4 is released!";
string
Body
= "Download
NoClone 4 at http://noclone.net now!";
//Create a SpreadWebService
object and use its method.
SpreadWebService MySpread = new
SpreadWebService();
string result = MySpread.send2(LoginName,LoginPassword,CampaignName,From,FromName,To,Subject,Body);
Dim
LoginName
As String =
"spread@reasonables.com"
Dim
LoginPassword
As String =
"spread"
Dim
CampaignName
As String =
"Noclone
campaign"
'Define the from
infomation
Dim From
As String =
"myedm@edm.com"
Dim
FromName
As
String=
"Reasonable"
'Define
recipient email
Dim To
As
String=
"noclone@reasonables.com"
'Define
the email subject and content
Dim Subject
As
String=
"NoClone
4 is released!"
Dim Body
As
String=
"Download
NoClone 4 at http://noclone.net now!"
'Create a SpreadWebService
object and use its method.
Dim
MySpread
As New SpreadWebService
Dim
Result As String= MySpread.send2(LoginName,
LoginPassword,CampaignName, From,FromName, To,Subject,Body)
/**
* @name send2
* @function send email one by one
* @return
* 'Invalid Email Address'
* 'Information required'
* 'LoginEmail and Password do not match'
* 'Sent failed'
* 'Your email has submitted successfully and will by send out soon.'
* 'Sent success'
*/
public function send2($loginEmail,$assword,$actName,$from,$fromName,$toEmail,$Msubject,$Mbody){
$sendParam = array(
'LoginEmail' => $loginEmail,
'Password' => $password,
'CampaignName' => empty( $actName ) ? SITE_DOMAIN.'_act_'.date( 'Y-n-j' ) : $actName,
'From' => $from,
'FromName' => $fromName,
'To' => $toEmail,
'Subject' => $Msubject,
'Body' => $Mbody
);
$Client=new SoapClient("http://service.rspread.com/Service.asmx?WSDL");
error_log( json_encode( $sendParam )."__param" );
$sendResult = $Client -> Send2( $sendParam );
return $sendResult;
}
No sample.