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


PHP JoomlapackHelperUtils::getJoomlaPackVersion方法代码示例

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


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

示例1: getIconDefinitions

 /**
  * Get an array of icon definitions for the Control Panel
  *
  * @return array
  */
 function getIconDefinitions()
 {
     jpimport('helpers.utils', true);
     JoomlapackHelperUtils::getJoomlaPackVersion();
     $ret = array();
     $registry =& JoomlapackModelRegistry::getInstance();
     if ($registry->get('easymode', false)) {
         $ret[] = $this->_makeIconDefinition('reset.png', JText::_('SWITCHTOPRO'), 'switch');
         $ret[] = $this->_makeIconDefinition('config.png', JText::_('CONFIGURATION'), 'configeasy');
         $ret[] = $this->_makeIconDefinition('backup.png', JText::_('BACKUP'), 'backup');
         $ret[] = $this->_makeIconDefinition('bufa.png', JText::_('BUADMIN'), 'buadmin');
         $ret[] = $this->_makeIconDefinition('log.png', JText::_('VIEWLOG'), 'log');
     } else {
         $ret[] = $this->_makeIconDefinition('reset.png', JText::_('SWITCHTOEASY'), 'switch');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('profiles.png', JText::_('PROFILES'), 'profiles');
         }
         $ret[] = $this->_makeIconDefinition('config.png', JText::_('CONFIGURATION'), 'config');
         $ret[] = $this->_makeIconDefinition('backup.png', JText::_('BACKUP'), 'backup');
         $ret[] = $this->_makeIconDefinition('bufa.png', JText::_('BUADMIN'), 'buadmin');
         $ret[] = $this->_makeIconDefinition('log.png', JText::_('VIEWLOG'), 'log');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('multidb.png', $this->_labelInclusion(JText::_('MULTIDB'), 'multidb'), 'multidb');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('dif.png', $this->_labelInclusion(JText::_('EXTRADIRS'), 'eff'), 'eff');
         }
         $ret[] = $this->_makeIconDefinition('sff.png', $this->_labelExclusion(JText::_('SFF'), 'sff'), 'sff');
         $ret[] = $this->_makeIconDefinition('def.png', $this->_labelExclusion(JText::_('DEF'), 'def'), 'def');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('full.png', $this->_labelExclusion(JText::_('DCS'), array('Skipfiles', 'Skipdirs')), 'skip');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('dbef.png', $this->_labelExclusion(JText::_('DBEF'), 'dbef'), 'dbef');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('extfilter.png', $this->_labelExclusion(JText::_('EXTFILTER'), array('components', 'modules', 'plugins', 'languages', 'templates')), 'extfilter');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('cronman.png', JText::_('CRONMAN'), 'cronman');
         }
         //$ret[] = $this->_makeIconDefinition( 'ftp.png', JText::_('FTPXFERWIZARD'), 'ftpx' );
     }
     // Add Live Update button if it is supported on this server
     jpimport('models.update', true);
     $updatemodel =& JoomlapackModelUpdate::getInstance('update', 'JoomlapackModel');
     if ($updatemodel->isLiveUpdateSupported()) {
         $updates =& $updatemodel->getUpdates();
         if ($updates->update_available) {
             $ret[] = $this->_makeIconDefinition('error_big.png', JText::_('CPANEL_UPGRADE_NOW'), 'update');
         } else {
             $ret[] = $this->_makeIconDefinition('ok_big.png', JText::_('CPANEL_UPGRADE_UPTODATE'), 'update');
         }
     }
     return $ret;
 }
开发者ID:BackupTheBerlios,项目名称:kmit-svn,代码行数:61,代码来源:cpanel.php

示例2: getStatusCell

 /**
  * Returns the HTML for the backup status cell
  *
  * @return string HTML
  */
 function getStatusCell()
 {
     if ($this->status && empty($this->quirks)) {
         $imageURL = JURI::base() . 'components/com_joomlapack/assets/images/ok_small.png';
         $html = '<p class="ok"><img src="' . $imageURL . '" border="0" width="16" height="16" />' . JText::_('JPSTATUSOK') . '</p>';
     } elseif ($this->status && !empty($this->quirks)) {
         $imageURL = JURI::base() . 'components/com_joomlapack/assets/images/ok_small.png';
         $html = '<p class="statuswarning"><img src="' . $imageURL . '" border="0" width="16" height="16" />' . JText::_('JPSTATUSWARN') . '</p>';
     } else {
         $imageURL = JURI::base() . 'components/com_joomlapack/assets/images/error_small.png';
         $html = '<p class="notok"><img src="' . $imageURL . '" border="0" width="16" height="16" />' . JText::_('JPSTATUSNOTOK') . '</p>';
     }
     jpimport('helpers.utils', true);
     JoomlapackHelperUtils::getJoomlaPackVersion();
     $html .= '<p><span style="font-size: small; color: #666666">' . JText::_('JOOMLAPACK') . ' ' . _JP_VERSION . ' (' . _JP_DATE . ')</span></p>';
     return $html;
 }
开发者ID:albertobraschi,项目名称:Hab,代码行数:22,代码来源:status.php

示例3: getIconDefinitions

 /**
  * Get an array of icon definitions for the Control Panel
  *
  * @return array
  */
 function getIconDefinitions()
 {
     jpimport('helpers.utils', true);
     JoomlapackHelperUtils::getJoomlaPackVersion();
     $ret = array();
     $registry =& JoomlapackModelRegistry::getInstance();
     if ($registry->get('easymode', false)) {
         $ret[] = $this->_makeIconDefinition('reset.png', JText::_('SWITCHTOPRO'), 'switch');
         $ret[] = $this->_makeIconDefinition('config.png', JText::_('CONFIGURATION'), 'configeasy');
         $ret[] = $this->_makeIconDefinition('backup.png', JText::_('BACKUP'), 'backup');
         $ret[] = $this->_makeIconDefinition('bufa.png', JText::_('BUADMIN'), 'buadmin');
         $ret[] = $this->_makeIconDefinition('log.png', JText::_('VIEWLOG'), 'log');
     } else {
         $ret[] = $this->_makeIconDefinition('reset.png', JText::_('SWITCHTOEASY'), 'switch');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('profiles.png', JText::_('PROFILES'), 'profiles');
         }
         $ret[] = $this->_makeIconDefinition('config.png', JText::_('CONFIGURATION'), 'config');
         $ret[] = $this->_makeIconDefinition('backup.png', JText::_('BACKUP'), 'backup');
         $ret[] = $this->_makeIconDefinition('bufa.png', JText::_('BUADMIN'), 'buadmin');
         $ret[] = $this->_makeIconDefinition('log.png', JText::_('VIEWLOG'), 'log');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('multidb.png', $this->_labelInclusion(JText::_('MULTIDB'), 'multidb'), 'multidb');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('dif.png', $this->_labelInclusion(JText::_('EXTRADIRS'), 'eff'), 'eff');
         }
         $ret[] = $this->_makeIconDefinition('sff.png', $this->_labelExclusion(JText::_('SFF'), 'sff'), 'sff');
         $ret[] = $this->_makeIconDefinition('def.png', $this->_labelExclusion(JText::_('DEF'), 'def'), 'def');
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('full.png', $this->_labelExclusion(JText::_('DCS'), array('Skipfiles', 'Skipdirs')), 'skip');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('dbef.png', $this->_labelExclusion(JText::_('DBEF'), 'dbef'), 'dbef');
         }
         if (JPSPECIALEDITION) {
             $ret[] = $this->_makeIconDefinition('extfilter.png', $this->_labelExclusion(JText::_('EXTFILTER'), array('components', 'modules', 'plugins', 'languages', 'templates')), 'extfilter');
         }
         //$ret[] = $this->_makeIconDefinition( 'ftp.png', JText::_('FTPXFERWIZARD'), 'ftpx' );
     }
     return $ret;
 }
开发者ID:albertobraschi,项目名称:Hab,代码行数:47,代码来源:cpanel.php

示例4: jimport

 /**
  * Searches for updates and returns an object containing update information
  * @return JObject An object with members: supported, update_available,
  * 				   current_version, current_date, latest_version, latest_date,
  * 				   package_url
  */
 function &getUpdates($force = false)
 {
     jimport('joomla.utilities.date');
     $ret = new JObject();
     if (!$this->isLiveUpdateSupported()) {
         $ret->supported = false;
         $ret->update_available = false;
         return $ret;
     } else {
         $ret->supported = true;
         $update = $this->_getLatestVersion($force);
         // Check if we need to upgrade, by release date
         jimport('joomla.utilities.date');
         jpimport('helpers.utils', true);
         JoomlapackHelperUtils::getJoomlaPackVersion();
         $curdate = new JDate(_JP_DATE);
         $curdate = $curdate->toUnix(false);
         if (is_object($update->reldate)) {
             $reldate = $update->reldate->toUnix(false);
             $ret->latest_date = $update->reldate->toFormat('%Y-%m-%d');
         } else {
             $ret->latest_date = @date('Y-m-d', $update->reldate);
         }
         $ret->update_available = $reldate > $curdate;
         $ret->current_version = _JP_VERSION;
         $ret->current_date = _JP_DATE;
         $ret->latest_version = $update->version;
         $ret->status = $update->status;
         $ret->package_url = JPSPECIALEDITION ? $update->special : $update->free;
         return $ret;
     }
 }
开发者ID:jnvilo,项目名称:tomasinasanctuary.org,代码行数:38,代码来源:update.php

示例5: htmlentities

<br/>
<?php 
        echo JText::_('UPDATE_LABEL_PACKAGELOCATION');
        ?>
 <a href="<?php 
        echo $this->updates->package_url;
        ?>
">
<?php 
        echo htmlentities($this->updates->package_url);
        ?>
</a>
</p>
<?php 
        jpimport('helpers.utils', true);
        JoomlapackHelperUtils::getJoomlaPackVersion();
        if (substr(_JP_VERSION, 0, 3) == 'svn') {
            ?>
<p><?php 
            echo JText::_('UPDATE_LABEL_NOUPGRADESFOUND_INFO_SVN');
            ?>
</p>
<?php 
        } else {
            ?>
<p><?php 
            echo JText::_('UPDATE_LABEL_NOUPGRADESFOUND_INFO');
            ?>
</p>
<?php 
        }
开发者ID:jnvilo,项目名称:tomasinasanctuary.org,代码行数:31,代码来源:default.php

示例6: start

 /**
  * Initialises CUBE to start a new backup
  *
  */
 function start($description, $comment)
 {
     global $mainframe;
     // Load registry
     $configuration =& JoomlapackModelRegistry::getInstance();
     $configuration->reload();
     // Load engine provisioning object
     $this->provisioning =& JoomlapackCUBEProvisioning::getInstance();
     // Initialize statistics model
     $this->statmodel =& JoomlapackModelStatistics::getInstance();
     // Initialize private fields
     $this->_activeDomain = 'init';
     $this->_object = null;
     $this->_isFinished = false;
     // Load JP version
     JoomlapackHelperUtils::getJoomlaPackVersion();
     // Initialise log file
     JoomlapackLogger::ResetLog();
     JoomlapackLogger::WriteLog(_JP_LOG_INFO, "--------------------------------------------------------------------------------");
     JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JoomlaPack " . _JP_VERSION . ' (' . _JP_DATE . ')');
     JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Got backup?");
     JoomlapackLogger::WriteLog(_JP_LOG_INFO, "--------------------------------------------------------------------------------");
     // PHP configuration variables are tried to be logged only for debug and info log levels
     if ($configuration->get('logLevel') >= 2) {
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "--- System Information ---");
         if (function_exists('phpversion')) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "PHP Version        :" . phpversion());
         }
         if (function_exists('php_uname')) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "OS Version         :" . php_uname('s'));
         }
         $db =& JFactory::getDBO();
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "DB Version         :" . $db->getVersion());
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "DB Collation       :" . $db->getCollation());
         if (isset($_SERVER['SERVER_SOFTWARE'])) {
             $server = $_SERVER['SERVER_SOFTWARE'];
         } else {
             if ($sf = getenv('SERVER_SOFTWARE')) {
                 $server = $sf;
             } else {
                 $server = JText::_('n/a');
             }
         }
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Web Server         :" . $server);
         if (function_exists('php_sapi_name')) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "PHP Interface      :" . php_sapi_name());
         }
         $version = new JVersion();
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Joomla! version    :" . $version->getLongVersion());
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "User agent         :" . phpversion() <= "4.2.1" ? getenv("HTTP_USER_AGENT") : $_SERVER['HTTP_USER_AGENT']);
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Safe mode          :" . ini_get("safe_mode"));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Display errors     :" . ini_get("display_errors"));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Error reporting    :" . error2string());
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Disabled functions :" . ini_get("disable_functions"));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "open_basedir restr.:" . ini_get('open_basedir'));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Max. exec. time    :" . ini_get("max_execution_time"));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Memory limit       :" . ini_get("memory_limit"));
         if (function_exists("memory_get_usage")) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Current mem. usage :" . memory_get_usage());
         }
         if (function_exists("gzcompress")) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "GZIP Compression   : available (good)");
         } else {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "GZIP Compression   : n/a (no compression)");
         }
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JPATH_BASE         :" . JPATH_BASE);
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JPATH_ROOT         :" . JPATH_ROOT);
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JPATH_CACHE        :" . JPATH_CACHE);
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Output directory   :" . $configuration->get('OutputDirectory'));
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Temporary directory:" . $configuration->getTemporaryDirectory());
         $temp = JoomlapackCUBETables::_getBase64() ? 'Available; will be used for temp vars' : 'Not available';
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "BASE64 Encoding    :" . $temp);
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "--------------------------------------------------------------------------------");
     }
     jpimport('helpers.status', true);
     $statushelper =& JoomlapackHelperStatus::getInstance();
     if ($statushelper->hasQuirks()) {
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JoomlaPack has detected the following potential problems:");
         foreach ($statushelper->quirks as $q) {
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, '- ' . $q['code'] . ' ' . $q['description'] . ' (' . $q['severity'] . ')');
         }
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "You probably do not have to worry about them, but you should be aware of them.");
         JoomlapackLogger::WriteLog(_JP_LOG_INFO, "--------------------------------------------------------------------------------");
     }
     // Get current profile ID
     $session =& JFactory::getSession();
     $profile_id = $session->get('profile', null, 'joomlapack');
     JoomlapackLogger::WriteLog(_JP_LOG_INFO, "Loading profile #{$profile_id}");
     // Get archive name
     switch ($configuration->get('BackupType')) {
         case 'dbonly':
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JoomlaPack is starting a new database backup");
             $extension = '.sql';
             break;
         case 'full':
             JoomlapackLogger::WriteLog(_JP_LOG_INFO, "JoomlaPack is starting a new full site backup");
//.........这里部分代码省略.........
开发者ID:albertobraschi,项目名称:Hab,代码行数:101,代码来源:cube.php


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