public function get()
 {
     if (!$this->isDebugModeEnabled()) {
         return '';
     }
     if (!in_array($this->sStructureType, array('widget', 'post_meta_box', 'page_meta_box', 'user_meta'))) {
         return '';
     }
     return "<div class='amazon-auto-links-info'>" . $this->oMsg->get('debug_info') . ': ' . AmazonAutoLinks_AdminPageFramework_Registry::NAME . ' ' . AmazonAutoLinks_AdminPageFramework_Registry::getVersion() . "</div>";
 }
 private static function _getLogHeadingLine($fCurrentTimeStamp, $nElapsed, $sCallerClass, $sCallerFunction)
 {
     static $_iPageLoadID;
     static $_nGMTOffset;
     $_nGMTOffset = isset($_nGMTOffset) ? $_nGMTOffset : get_option('gmt_offset');
     $_iPageLoadID = $_iPageLoadID ? $_iPageLoadID : uniqid();
     $_nNow = $fCurrentTimeStamp + $_nGMTOffset * 60 * 60;
     $_nMicroseconds = str_pad(round(($_nNow - floor($_nNow)) * 10000), 4, '0');
     $_aOutput = array(date("Y/m/d H:i:s", $_nNow) . '.' . $_nMicroseconds, self::_getFormattedElapsedTime($nElapsed), $_iPageLoadID, AmazonAutoLinks_AdminPageFramework_Registry::getVersion(), $sCallerClass . '::' . $sCallerFunction, current_filter(), self::getCurrentURL());
     return implode(' ', $_aOutput);
 }
Exemplo n.º 3
0
 public function __construct($sLibraryPath = __FILE__)
 {
     if (!$this->_isLoadable()) {
         return;
     }
     AmazonAutoLinks_AdminPageFramework_Registry::setUp($sLibraryPath);
     if (AmazonAutoLinks_AdminPageFramework_Registry::$bIsMinifiedVersion) {
         return;
     }
     include AmazonAutoLinks_AdminPageFramework_Registry::$sAutoLoaderPath;
     new AmazonAutoLinks_AdminPageFramework_RegisterClasses(empty(AmazonAutoLinks_AdminPageFramework_Registry::$aClassFiles) ? AmazonAutoLinks_AdminPageFramework_Registry::$sDirPath : '', array('exclude_class_names' => array('AmazonAutoLinks_AdminPageFramework_MinifiedVersionHeader', 'AmazonAutoLinks_AdminPageFramework_BeautifiedVersionHeader')), AmazonAutoLinks_AdminPageFramework_Registry::$aClassFiles);
     AmazonAutoLinks_AdminPageFramework_Registry::$bIsDevelopmentVersion = class_exists('AmazonAutoLinks_AdminPageFramework_InclusionClassFilesHeader');
 }
 public static function _setLibraryData()
 {
     self::$_aLibraryData = array('sName' => AmazonAutoLinks_AdminPageFramework_Registry::NAME, 'sURI' => AmazonAutoLinks_AdminPageFramework_Registry::URI, 'sScriptName' => AmazonAutoLinks_AdminPageFramework_Registry::NAME, 'sLibraryName' => AmazonAutoLinks_AdminPageFramework_Registry::NAME, 'sLibraryURI' => AmazonAutoLinks_AdminPageFramework_Registry::URI, 'sPluginName' => '', 'sPluginURI' => '', 'sThemeName' => '', 'sThemeURI' => '', 'sVersion' => AmazonAutoLinks_AdminPageFramework_Registry::getVersion(), 'sDescription' => AmazonAutoLinks_AdminPageFramework_Registry::DESCRIPTION, 'sAuthor' => AmazonAutoLinks_AdminPageFramework_Registry::AUTHOR, 'sAuthorURI' => AmazonAutoLinks_AdminPageFramework_Registry::AUTHOR_URI, 'sTextDomain' => AmazonAutoLinks_AdminPageFramework_Registry::TEXT_DOMAIN, 'sDomainPath' => AmazonAutoLinks_AdminPageFramework_Registry::TEXT_DOMAIN_PATH, 'sNetwork' => '', '_sitewide' => '');
     return self::$_aLibraryData;
 }
 public static function getFrameworkVersion($bTrimDevVer = false)
 {
     $_sVersion = AmazonAutoLinks_AdminPageFramework_Registry::getVersion();
     return $bTrimDevVer ? self::getSuffixRemoved($_sVersion, '.dev') : $_sVersion;
 }
 private function _getFormattedSystemInformation($asCustomData)
 {
     $_aData = $this->getAsArray($asCustomData);
     $_aData = $_aData + array('Admin Page Framework' => isset($_aData['Admin Page Framework']) ? null : AmazonAutoLinks_AdminPageFramework_Registry::getInfo(), 'WordPress' => $this->_getSiteInfoWithCache(!isset($_aData['WordPress'])), 'PHP' => $this->_getPHPInfo(!isset($_aData['PHP'])), 'PHP Error Log' => $this->_getErrorLogByType('php', !isset($_aData['PHP Error Log'])), 'MySQL' => isset($_aData['MySQL']) ? null : $this->getMySQLInfo(), 'MySQL Error Log' => $this->_getErrorLogByType('mysql', !isset($_aData['MySQL Error Log'])), 'Server' => $this->_getWebServerInfo(!isset($_aData['Server'])), 'Browser' => $this->_getClientInfo(!isset($_aData['Browser'])));
     return array_filter($_aData);
 }