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


PHP Provider::FromVerificationCode方法代码示例

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


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

示例1: __Construct

 function __Construct($user, $dictionary)
 {
     parent::__Construct(get_class());
     $success = false;
     $message = '';
     if (HTTP::IsPost()) {
         $verificationCode = Params::Get('verificationCode');
         $verifierName = Params::Get('verifierName');
         if (!is_null($verificationCode) && !is_null($verifierName)) {
             $provider = Provider::FromVerificationCode($verificationCode);
             if (!is_null($provider)) {
                 $reference = 'UserId:' . $user->getId();
                 $provider->verify($verifierName, $reference);
                 $success = true;
             }
         }
     } else {
         $message = "NO DATA POSTED";
     }
     //done
     $this->jsonData = array('success' => $success, 'message' => $message);
 }
开发者ID:TreatNOW,项目名称:TNfrontend,代码行数:22,代码来源:VerifyProviderResponse.inc.php

示例2: __Construct

 function __Construct($user, $dictionary)
 {
     parent::__Construct(get_class());
     $success = false;
     $message = '';
     if (HTTP::IsPost()) {
         $verificationCode = Params::Get('verificationCode');
         $verifierName = Params::Get('verifierName');
         $feedback = Params::Get('feedback');
         if (!is_null($verificationCode) && !is_null($verifierName) && !is_null($feedback)) {
             $provider = Provider::FromVerificationCode($verificationCode);
             if (!is_null($provider)) {
                 //add provider event
                 $reference = 'UserId:' . $user->getId();
                 $notes = "Submitted by:" . $verifierName . "\n" . $feedback;
                 $provider->addEvent(ProviderEventType::VERIFICATION_FEEDBACK, $reference, $notes);
                 $success = true;
                 //notify email
                 $partner = new Partner(Application::PARTNER_CODE);
                 $recipientAddress = $partner->getConfigValue(PartnerConfig::COMMS_NOTIFY_EMAIL);
                 $content = "\n";
                 $content .= "Some feedback has been submitted regarding provider data.\n\n";
                 $content .= '---------------------------------------------------------------------' . "\n";
                 $content .= "Provider: " . $provider->getName() . "\n";
                 $content .= "Submitted by: " . $verifierName . "\n";
                 $content .= "Feedback: \n";
                 $content .= $feedback . "\n";
                 $content .= '---------------------------------------------------------------------' . "\n\n";
                 Application::SendEmail('notifications@zidmi.com', 'Zidmi', null, $recipientAddress, 'Provider Verification Feedback', $content);
             }
         }
     } else {
         $message = "NO DATA POSTED";
     }
     //done
     $this->jsonData = array('success' => $success, 'message' => $message);
 }
开发者ID:TreatNOW,项目名称:TNfrontend,代码行数:37,代码来源:VerifyFeedbackResponse.inc.php

示例3: Dictionary

 $dictionary = new Dictionary($langCode, 'treatnow.');
 //if at root then load HomePage or MobilePage
 if ($element0 == '') {
     if ($client == 'mobile') {
         $response = new MobilePage($dictionary);
     } else {
         $response = new HomePage($dictionary);
     }
 } else {
     //special cases
     if ($element0 == 'contact') {
         $response = new HomePage($dictionary, true);
     } elseif ($element0 == 'sitemap') {
         $response = new SitemapResponse();
     } elseif ($element0 == 'verify') {
         $provider = Provider::FromVerificationCode($element1);
         if (!is_null($provider)) {
             $response = new ProviderSetupPage($dictionary, $provider);
         }
     } elseif ($element0 == 'stripe-setup') {
         $provider = Provider::FromPaymentConfigCode($element1);
         if (!is_null($provider)) {
             $response = new StripeSetupPage($dictionary, $provider);
         }
     } elseif ($element0 == 'stripe-return') {
         $response = new StripeReturnPage($dictionary);
     } elseif ($client == 'mobile' && $element0 == 'static') {
         $response = new MobileHoldingPage($dictionary);
     } else {
         //cmsPage
         $cmsPage = null;
开发者ID:TreatNOW,项目名称:TNfrontend,代码行数:31,代码来源:index.php


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