Exemple #1
0
 /**
  * Get sign in return URL
  *
  * @param boolean $withProto If true - return URL with protocol (http|https), else - without protocol
  *
  * @return string
  */
 protected function getSignInReturnURL($withProto = true)
 {
     $api = new \XLite\Module\CDev\Paypal\Core\Login();
     $flag = $withProto ? null : false;
     // Get Return URL with protocol 'http'
     $returnURL = $api->getSignInReturnURL($flag);
     if (!$withProto) {
         $returnURL = preg_replace('/^http/', '', $returnURL);
     }
     return $returnURL;
 }
Exemple #2
0
 /**
  * Preprocessor for no-action run
  *
  * @return void
  */
 protected function doNoAction()
 {
     $api = new \XLite\Module\CDev\Paypal\Core\Login();
     $url = $api->getSignInURL();
     $this->redirect($url);
 }