当前位置: 首页>>代码示例>>PHP>>正文


PHP SoapClient::receiverSetInactive方法代码示例

本文整理汇总了PHP中SoapClient::receiverSetInactive方法的典型用法代码示例。如果您正苦于以下问题:PHP SoapClient::receiverSetInactive方法的具体用法?PHP SoapClient::receiverSetInactive怎么用?PHP SoapClient::receiverSetInactive使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在SoapClient的用法示例。


在下文中一共展示了SoapClient::receiverSetInactive方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: removeReceiver

 /**
  *
  * @return void
  */
 protected function removeReceiver()
 {
     $soap = new SoapClient($this->settings['wsdlUrl']);
     $userdata = $this->parseFields('fields.');
     if ($this->settings['directUnsubscription'] == "1") {
         if ($this->settings['unsubscribemethod'] == "delete") {
             $return = $soap->receiverDelete($this->settings['apiKey'], $this->settings['listId'], $userdata['email']);
         } else {
             $return = $soap->receiverSetInactive($this->settings['apiKey'], $this->settings['listId'], $userdata['email']);
         }
         if ($return->status == Tx_Formhandler_Finisher_CleverReach::STATUS_SUCCESS) {
             $this->utilityFuncs->debugMessage("User removed successfully");
         } else {
             $this->utilityFuncs->debugMessage("Error at removing \"" . $userdata['email'] . "\": " . $return->message);
         }
     } else {
         $return = $soap->formsUnsubscribeMail($this->settings['apiKey'], $this->settings['formId'], $userdata['email']);
         if ($return->status == Tx_Formhandler_Finisher_CleverReach::STATUS_SUCCESS) {
             $this->utilityFuncs->debugMessage("Unsubscribe mail sent");
         } else {
             $this->utilityFuncs->debugMessage("Unsubscription error for \"" . $userdata['email'] . "\": " . $return->message);
         }
     }
 }
开发者ID:raimundlandig,项目名称:winkel.de-DEV,代码行数:28,代码来源:Tx_Formhandler_Finisher_Unsubscribe.php

示例2: array

     $res = mysql_query($query);
     if ($res && mysql_num_rows($res)) {
         $old_email_address = mysql_result($res, 0, 0);
     }
     if ($old_email_address != $customers_email_address) {
         $client->receiverDelete(CR_API_KEY, CR_LIST_ID, $old_email_address);
         $crReceiver = array('email' => utf8_encode($customers_email_address), 'source' => utf8_encode('SwissCart'), 'attributes' => array(0 => array('key' => 'firstname', 'value' => utf8_encode($customers_firstname)), 1 => array('key' => 'lastname', 'value' => utf8_encode($customers_lastname))));
         $client->receiverAdd(CR_API_KEY, CR_LIST_ID, $crReceiver);
     } else {
         $crReceiver = array('email' => utf8_encode($customers_email_address), 'source' => utf8_encode('SwissCart'), 'attributes' => array(0 => array('key' => 'firstname', 'value' => utf8_encode($customers_firstname)), 1 => array('key' => 'lastname', 'value' => utf8_encode($customers_lastname))));
         $client->receiverUpdate(CR_API_KEY, CR_LIST_ID, $crReceiver);
     }
     if ($customers_newsletter) {
         $client->receiverSetActive(CR_API_KEY, CR_LIST_ID, utf8_encode($customers_email_address));
     } else {
         $client->receiverSetInactive(CR_API_KEY, CR_LIST_ID, utf8_encode($customers_email_address));
     }
 }
 //------------------------------ CleverReach Ends --------------------------------------
 $sql_data_array = array('customers_firstname' => $customers_firstname, 'customers_lastname' => $customers_lastname, 'customers_email_address' => $customers_email_address, 'customers_telephone' => $customers_telephone, 'customers_fax' => $customers_fax, 'customers_newsletter' => $customers_newsletter);
 if (ACCOUNT_GENDER == 'true') {
     $sql_data_array['customers_gender'] = $customers_gender;
 }
 if (ACCOUNT_DOB == 'true') {
     $sql_data_array['customers_dob'] = tep_date_raw($customers_dob);
 }
 tep_db_perform(TABLE_CUSTOMERS, $sql_data_array, 'update', "customers_id = '" . (int) $customers_id . "'");
 tep_db_query("update " . TABLE_CUSTOMERS_INFO . " set customers_info_date_account_last_modified = now() where customers_info_id = '" . (int) $customers_id . "'");
 if ($entry_zone_id > 0) {
     $entry_state = '';
 }
开发者ID:sfxonline,项目名称:oscommerce-cleverreach,代码行数:31,代码来源:customers.php

示例3: values

     }
 }
 tep_db_perform(TABLE_ADDRESS_BOOK, $sql_data_array);
 $address_id = tep_db_insert_id();
 tep_db_query("update " . TABLE_CUSTOMERS . " set customers_default_address_id = '" . (int) $address_id . "' where customers_id = '" . (int) $customer_id . "'");
 tep_db_query("insert into " . TABLE_CUSTOMERS_INFO . " (customers_info_id, customers_info_number_of_logons, customers_info_date_account_created) values ('" . (int) $customer_id . "', '0', now())");
 if (SESSION_RECREATE == 'True') {
     tep_session_recreate();
 }
 //----------------------------- CleverReach Starts --------------------------------------
 if (CR_ENABLED == 'true') {
     $client = new SoapClient('http://api.cleverreach.com/soap/interface_v5.1.php?wsdl');
     $crReceiver = array('email' => utf8_encode($email_address), 'source' => utf8_encode('SwissCart'), 'attributes' => array(0 => array('key' => 'firstname', 'value' => utf8_encode($firstname)), 1 => array('key' => 'lastname', 'value' => utf8_encode($lastname))));
     $client->receiverAdd(CR_API_KEY, CR_LIST_ID, $crReceiver);
     if (!$newsletter) {
         $client->receiverSetInactive(CR_API_KEY, CR_LIST_ID, $email_address);
     }
 }
 //------------------------------ CleverReach Ends --------------------------------------
 $customer_first_name = $firstname;
 $customer_default_address_id = $address_id;
 $customer_country_id = $country;
 $customer_zone_id = $zone_id;
 tep_session_register('customer_id');
 tep_session_register('customer_first_name');
 tep_session_register('customer_default_address_id');
 tep_session_register('customer_country_id');
 tep_session_register('customer_zone_id');
 // reset session token
 $sessiontoken = md5(tep_rand() . tep_rand() . tep_rand() . tep_rand());
 // restore cart contents
开发者ID:sfxonline,项目名称:oscommerce-cleverreach,代码行数:31,代码来源:create_account.php

示例4: SoapClient

$newsletter = tep_db_fetch_array($newsletter_query);
if (isset($HTTP_POST_VARS['action']) && $HTTP_POST_VARS['action'] == 'process' && isset($HTTP_POST_VARS['formid']) && $HTTP_POST_VARS['formid'] == $sessiontoken) {
    if (isset($HTTP_POST_VARS['newsletter_general']) && is_numeric($HTTP_POST_VARS['newsletter_general'])) {
        $newsletter_general = tep_db_prepare_input($HTTP_POST_VARS['newsletter_general']);
    } else {
        $newsletter_general = '0';
    }
    if ($newsletter_general != $newsletter['customers_newsletter']) {
        $newsletter_general = $newsletter['customers_newsletter'] == '1' ? '0' : '1';
        //----------------------------- CleverReach Starts --------------------------------------
        if (CR_ENABLED == 'true') {
            $query = tep_db_query("select customers_email_address from " . TABLE_CUSTOMERS . " where customers_id = '" . (int) $customer_id . "'");
            $customer = tep_db_fetch_array($query);
            $client = new SoapClient('http://api.cleverreach.com/soap/interface_v5.1.php?wsdl');
            if ($newsletter['customers_newsletter'] == '1') {
                $client->receiverSetInactive(CR_API_KEY, CR_LIST_ID, $customer['customers_email_address']);
            } else {
                $client->receiverSetActive(CR_API_KEY, CR_LIST_ID, $customer['customers_email_address']);
            }
        }
        //------------------------------ CleverReach Ends --------------------------------------
        tep_db_query("update " . TABLE_CUSTOMERS . " set customers_newsletter = '" . (int) $newsletter_general . "' where customers_id = '" . (int) $customer_id . "'");
    }
    $messageStack->add_session('account', SUCCESS_NEWSLETTER_UPDATED, 'success');
    tep_redirect(tep_href_link(FILENAME_ACCOUNT, '', 'SSL'));
}
$breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_ACCOUNT, '', 'SSL'));
$breadcrumb->add(NAVBAR_TITLE_2, tep_href_link(FILENAME_ACCOUNT_NEWSLETTERS, '', 'SSL'));
require DIR_WS_INCLUDES . 'template_top.php';
?>
开发者ID:sfxonline,项目名称:oscommerce-cleverreach,代码行数:30,代码来源:account_newsletters.php


注:本文中的SoapClient::receiverSetInactive方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。