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


PHP CBPTXT::jsAddSlashes方法代码示例

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


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

示例1: _outputInstructions

 /**
  * Private method to output the payment instructions
  * @param  cbpaidPaymentBasket  $paymentBasket
  * @return bool|string
  */
 private function _outputInstructions($paymentBasket)
 {
     if ($paymentBasket->payment_method == 'offline' || $paymentBasket->payment_method == null) {
         if ($paymentBasket->payment_method == null) {
             $paymentBasket->payment_method = $this->getPayName();
             $paymentBasket->gateway_account = $this->getAccountParam('id');
             $paymentBasket->store();
         }
         // Generate URLs for payment slip:
         $slip_popup_window = $this->getAccountParam('slip_popup_window', 1);
         $slip_urlHtmlSpecialchared = $this->_getSlipUrlHtmlSpecialchared($paymentBasket, $slip_popup_window);
         $slip_link_text = CBPTXT::Th($this->getAccountParam('slip_link_text', "Click here to confirm that you are paying off-line and to display the Payment slip to print"));
         $areYouSureText = CBPTXT::T($this->getAccountParam('slip_link_areyousure_text', "This will lock this transaction for offline payment. Please continue now only if you are preparing the payment now. Are you paying now ?"));
         $ret = "<div class=\"cbpaidInstructions\">" . CBPTXT::Th($this->getAccountParam('regOfflineInstructions')) . "</div>\n";
         $ret .= '<div class="cbpaySlip"><a ';
         if ($areYouSureText || $slip_popup_window) {
             $ret .= 'onclick="';
             if ($areYouSureText) {
                 $ret .= 'if ( confirm( \'' . CBPTXT::jsAddSlashes(htmlspecialchars($areYouSureText)) . '\' ) ) ';
             }
             if ($slip_popup_window) {
                 $ret .= 'window.open(\'' . $slip_urlHtmlSpecialchared . '\', \'payslip\', \'status=no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=640,height=480,directories=no,location=no\'); return false;" ' . 'target="_blank" ';
             } else {
                 $ret .= ' return true else return false;" ';
             }
         }
         $ret .= 'href="' . $slip_urlHtmlSpecialchared . '">' . $slip_link_text . "</a></div>\n";
     } else {
         $this->_setErrorMSG(CBPTXT::T("Another payment method has already been choosen to pay."));
         $ret = false;
     }
     return $ret;
 }
开发者ID:jasonrgd,项目名称:Digital-Publishing-Platform-Joomla,代码行数:38,代码来源:cbpaidsubscriptions.offline.php


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