本文整理匯總了PHP中InboundEmail::getSessionInboundDelimiterString方法的典型用法代碼示例。如果您正苦於以下問題:PHP InboundEmail::getSessionInboundDelimiterString方法的具體用法?PHP InboundEmail::getSessionInboundDelimiterString怎麽用?PHP InboundEmail::getSessionInboundDelimiterString使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類InboundEmail
的用法示例。
在下文中一共展示了InboundEmail::getSessionInboundDelimiterString方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: isset
if (isset($_REQUEST['is_create_case']) && $_REQUEST['is_create_case'] == 'on') {
$focus->mailbox_type = 'createcase';
} else {
if (empty($focus->mailbox_type) || $focus->mailbox_type == 'createcase') {
$focus->mailbox_type = 'pick';
}
}
/////////////////////////////////////////////////////////
//// SERVICE STRING CONCATENATION
$useSsl = isset($_REQUEST['ssl']) && $_REQUEST['ssl'] == 1 ? true : false;
$optimum = $focus->getSessionConnectionString($focus->server_url, $focus->email_user, $focus->port, $focus->protocol);
if (empty($optimum)) {
$optimum = $focus->findOptimumSettings($useSsl, $focus->email_user, $focus->email_password, $focus->server_url, $focus->port, $focus->protocol, $focus->mailbox);
}
// if
$delimiter = $focus->getSessionInboundDelimiterString($focus->server_url, $focus->email_user, $focus->port, $focus->protocol);
//added check to ensure the $optimum['serial']) is not empty.
if (is_array($optimum) && count($optimum) > 0 && !empty($optimum['serial'])) {
$focus->service = $optimum['serial'];
} else {
// no save
// allowing bad save to allow Email Campaigns configuration to continue even without IMAP
$focus->service = "::::::" . $focus->protocol . "::::";
// save bogus info.
$error = "&error=true";
}
//// END SERVICE STRING CONCAT
/////////////////////////////////////////////////////////
if (isset($_REQUEST['mark_read']) && $_REQUEST['mark_read'] == 1) {
$focus->delete_seen = 0;
} else {
示例2: testgetSessionInboundDelimiterString
public function testgetSessionInboundDelimiterString()
{
$inboundEmail = new InboundEmail();
//test without setting session key
$result = $inboundEmail->getSessionInboundDelimiterString('mail.google.com', 'test', 22, 'IMAP');
$this->assertEquals('', $result);
//test with session key set
$_SESSION['mail.google.comtest22IMAPdelimiter'] = 'delimit string';
$result = $inboundEmail->getSessionInboundDelimiterString('mail.google.com', 'test', 22, 'IMAP');
$this->assertEquals('delimit string', $result);
}