當前位置: 首頁>>代碼示例>>PHP>>正文


PHP PagSeguroLibrary::getPath方法代碼示例

本文整理匯總了PHP中PagSeguroLibrary::getPath方法的典型用法代碼示例。如果您正苦於以下問題:PHP PagSeguroLibrary::getPath方法的具體用法?PHP PagSeguroLibrary::getPath怎麽用?PHP PagSeguroLibrary::getPath使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在PagSeguroLibrary的用法示例。


在下文中一共展示了PagSeguroLibrary::getPath方法的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: addClass

 private function addClass($dir, $class)
 {
     $file = PagSeguroLibrary::getPath() . DIRECTORY_SEPARATOR . $dir . DIRECTORY_SEPARATOR . $class . '.class.php';
     if (file_exists($file) && is_file($file)) {
         require_once $file;
     }
 }
開發者ID:kosmosby,項目名稱:medicine-prof,代碼行數:7,代碼來源:PagSeguroAutoLoader.class.php

示例2: __construct

 private function __construct()
 {
     define('ALLOW_PAGSEGURO_RESOURCES', true);
     require_once PagSeguroLibrary::getPath() . DIRECTORY_SEPARATOR . "resources" . DIRECTORY_SEPARATOR . "PagSeguroResources.php";
     $varName = self::VAR_NAME;
     if (isset(${$varName})) {
         self::$data = ${$varName};
         unset(${$varName});
     } else {
         throw new Exception("Resources is undefined.");
     }
 }
開發者ID:kennedimalheiros,項目名稱:prestashop,代碼行數:12,代碼來源:PagSeguroResources.class.php

示例3: __construct

 private function __construct()
 {
     define('ALLOW_PAGSEGURO_CONFIG', true);
     require_once PagSeguroLibrary::getPath() . DIRECTORY_SEPARATOR . "config" . DIRECTORY_SEPARATOR . "PagSeguroConfig.php";
     $varName = self::VARNAME;
     if (isset(${$varName})) {
         self::$data = ${$varName};
         unset(${$varName});
     } else {
         throw new Exception("Config is undefined.");
     }
 }
開發者ID:caina,項目名稱:pando,代碼行數:12,代碼來源:PagSeguroConfig.class.php

示例4: __autoload

 function __autoload($class)
 {
     $dirs = array('domain', 'exception', 'parser', 'service', 'utils', 'helper', 'config', 'resources', 'log');
     foreach ($dirs as $d) {
         $file = PagSeguroLibrary::getPath() . DIRECTORY_SEPARATOR . $d . DIRECTORY_SEPARATOR . $class . '.class.php';
         if (file_exists($file) && is_file($file)) {
             require_once $file;
             return true;
         }
     }
     return false;
 }
開發者ID:kosmosby,項目名稱:medicine-prof,代碼行數:12,代碼來源:PagSeguroAutoLoader.php

示例5: __construct

 private function __construct()
 {
     define('ALLOW_PAGSEGURO_CONFIG', true);
     if (!class_exists('PagSeguroConfigWrapper')) {
         require_once PagSeguroLibrary::getPath() . DIRECTORY_SEPARATOR . "config" . DIRECTORY_SEPARATOR . "PagSeguroConfigWrapper.php";
     }
     $wrapper = new PagSeguroConfigWrapper();
     if (method_exists($wrapper, 'getConfig')) {
         self::$data = $wrapper->getConfig();
     } else {
         throw new Exception("Config is undefined.");
     }
 }
開發者ID:vrenkanal,項目名稱:php,代碼行數:13,代碼來源:PagSeguroConfig.class.php

示例6: createFile

 /**
  * Creates the log file
  * @throws Exception
  * @return boolean
  */
 public static function createFile()
 {
     if (!self::$active) {
         return false;
     }
     $defaultPath = PagSeguroLibrary::getPath();
     $defaultName = 'PagSeguro.log';
     self::$fileLocation = $defaultPath . DIRECTORY_SEPARATOR . $defaultName;
     if ($f = @fopen(self::$fileLocation, "a")) {
         fclose($f);
     } else {
         throw new Exception("Can't create log file. Permission denied. File location: " . self::$fileLocation);
     }
 }
開發者ID:kosmosby,項目名稱:medicine-prof,代碼行數:19,代碼來源:LogPagSeguro.class.php

示例7: createFile

 /**
  * Creates the log file
  * @throws Exception
  * @return boolean
  */
 public static function createFile()
 {
     if (!self::$active) {
         return false;
     }
     $defaultPath = PagSeguroLibrary::getPath();
     $defaultName = 'PagSeguro.log';
     self::$fileLocation = $defaultPath . DIRECTORY_SEPARATOR . $defaultName;
     try {
         $f = fopen(self::$fileLocation, "a");
         fclose($f);
     } catch (Exception $e) {
         echo $e->getMessage() . " - Can't create log file. Permission denied. File location: " . self::$fileLocation;
     }
 }
開發者ID:rborgesds,項目名稱:FluxCP,代碼行數:20,代碼來源:LogPagSeguro.class.php

示例8: createFile

 public static function createFile($logFile = false)
 {
     if (!self::$active) {
         return false;
     }
     $defaultPath = PagSeguroLibrary::getPath();
     $defaultName = 'PagSeguro.log';
     self::$fileLocation = $logFile ? $logFile : $defaultPath . DIRECTORY_SEPARATOR . $defaultName;
     try {
         $f = fopen(self::$fileLocation, "a");
         if (!$f) {
             throw new Exception('Unable to open the input file');
         }
         fclose($f);
         return true;
     } catch (Exception $e) {
         echo $e->getMessage() . " - Can't create log file. Permission denied. File location: " . self::$fileLocation;
         return false;
     }
 }
開發者ID:caina,項目名稱:pando,代碼行數:20,代碼來源:LogPagSeguro.class.php

示例9: createFile

 public static function createFile()
 {
     if (!self::$active) {
         return false;
     }
     $defaultPath = PagSeguroLibrary::getPath();
     $defaultName = 'PagSeguro' . mt_rand() . '.log';
     self::$fileLocation = $defaultPath . DIRECTORY_SEPARATOR . $defaultName;
     Configuration::updateValue('PAGSEGURO_LOG_FILELOCATION', "/modules/pagseguro/features/PagSeguroLibrary/" . $defaultName);
     try {
         $f = fopen(self::$fileLocation, "a");
         if (!$f) {
             throw new Exception('Unable to open the input file');
         }
         fclose($f);
         return true;
     } catch (Exception $e) {
         echo $e->getMessage() . " - Can't create log file. Permission denied. File location: " . self::$fileLocation;
         return false;
     }
 }
開發者ID:franklindias,項目名稱:prestashop,代碼行數:21,代碼來源:LogPagSeguro.class.php


注:本文中的PagSeguroLibrary::getPath方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。