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


PHP License::isUpgradable方法代码示例

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


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

示例1: setLicensePlaceholders

 public function setLicensePlaceholders($template)
 {
     $date = $this->license->getValidToDate();
     if ($date) {
         $formattedValidityDate = date(ASCMS_DATE_FORMAT_DATE, $date);
     } else {
         $formattedValidityDate = '';
     }
     $date = $this->license->getCreatedAtDate();
     if ($date) {
         $formattedCreateDate = date(ASCMS_DATE_FORMAT_DATE, $date);
     } else {
         $formattedCreateDate = '';
     }
     $cdate = $this->license->getValidToDate();
     $today = time();
     $difference = $cdate - $today;
     if ($difference < 0) {
         $difference = 0;
     }
     $validDayCount = ceil($difference / 60 / 60 / 24) - 1;
     if ($validDayCount < 0) {
         $validDayCount = 0;
     }
     $template->setVariable(array('LICENSE_STATE' => $this->lang['TXT_LICENSE_STATE_' . $this->license->getState()], 'LICENSE_EDITION' => contrexx_raw2xhtml($this->license->getEditionName()), 'INSTALLATION_ID' => contrexx_raw2xhtml($this->license->getInstallationId()), 'LICENSE_KEY' => contrexx_raw2xhtml($this->license->getLicenseKey()), 'LICENSE_VALID_TO' => contrexx_raw2xhtml($formattedValidityDate), 'LICENSE_VALID_DAY_COUNT' => contrexx_raw2xhtml($validDayCount), 'LICENSE_CREATED_AT' => contrexx_raw2xhtml($formattedCreateDate), 'LICENSE_REQUEST_INTERVAL' => contrexx_raw2xhtml($this->license->getRequestInterval()), 'LICENSE_GRAYZONE_DAYS' => contrexx_raw2xhtml($this->license->getGrayzoneTime()), 'LICENSE_FRONTENT_OFFSET_DAYS' => contrexx_raw2xhtml($this->license->getFrontendLockTime()), 'LICENSE_UPGRADE_URL' => contrexx_raw2xhtml($this->license->getUpgradeUrl()), 'LICENSE_PARTNER_TITLE' => contrexx_raw2xhtml($this->license->getPartner()->getTitle()), 'LICENSE_PARTNER_LASTNAME' => contrexx_raw2xhtml($this->license->getPartner()->getLastname()), 'LICENSE_PARTNER_FIRSTNAME' => contrexx_raw2xhtml($this->license->getPartner()->getFirstname()), 'LICENSE_PARTNER_COMPANY' => contrexx_raw2xhtml($this->license->getPartner()->getCompanyName()), 'LICENSE_PARTNER_ADDRESS' => contrexx_raw2xhtml($this->license->getPartner()->getAddress()), 'LICENSE_PARTNER_ZIP' => contrexx_raw2xhtml($this->license->getPartner()->getZip()), 'LICENSE_PARTNER_CITY' => contrexx_raw2xhtml($this->license->getPartner()->getCity()), 'LICENSE_PARTNER_COUNTRY' => contrexx_raw2xhtml($this->license->getPartner()->getCountry()), 'LICENSE_PARTNER_PHONE' => contrexx_raw2xhtml($this->license->getPartner()->getPhone()), 'LICENSE_PARTNER_URL' => contrexx_raw2xhtml($this->license->getPartner()->getUrl()), 'LICENSE_PARTNER_MAIL' => contrexx_raw2xhtml($this->license->getPartner()->getMail()), 'LICENSE_CUSTOMER_TITLE' => contrexx_raw2xhtml($this->license->getCustomer()->getTitle()), 'LICENSE_CUSTOMER_LASTNAME' => contrexx_raw2xhtml($this->license->getCustomer()->getLastname()), 'LICENSE_CUSTOMER_FIRSTNAME' => contrexx_raw2xhtml($this->license->getCustomer()->getFirstname()), 'LICENSE_CUSTOMER_COMPANY' => contrexx_raw2xhtml($this->license->getCustomer()->getCompanyName()), 'LICENSE_CUSTOMER_ADDRESS' => contrexx_raw2xhtml($this->license->getCustomer()->getAddress()), 'LICENSE_CUSTOMER_ZIP' => contrexx_raw2xhtml($this->license->getCustomer()->getZip()), 'LICENSE_CUSTOMER_CITY' => contrexx_raw2xhtml($this->license->getCustomer()->getCity()), 'LICENSE_CUSTOMER_COUNTRY' => contrexx_raw2xhtml($this->license->getCustomer()->getCountry()), 'LICENSE_CUSTOMER_PHONE' => contrexx_raw2xhtml($this->license->getCustomer()->getPhone()), 'LICENSE_CUSTOMER_URL' => contrexx_raw2xhtml($this->license->getCustomer()->getUrl()), 'LICENSE_CUSTOMER_MAIL' => contrexx_raw2xhtml($this->license->getCustomer()->getMail()), 'VERSION_NUMBER' => contrexx_raw2xhtml($this->license->getVersion()->getNumber()), 'VERSION_NUMBER_INT' => contrexx_raw2xhtml($this->license->getVersion()->getNumber(true)), 'VERSION_NAME' => contrexx_raw2xhtml($this->license->getVersion()->getName()), 'VERSION_CODENAME' => contrexx_raw2xhtml($this->license->getVersion()->getCodeName()), 'VERSION_STATE' => contrexx_raw2xhtml($this->license->getVersion()->getState()), 'VERSION_RELEASE_DATE' => contrexx_raw2xhtml($this->license->getVersion()->getReleaseDate())));
     if ($template->blockExists('upgradable')) {
         if ($this->license->isUpgradable()) {
             $template->touchBlock('upgradable');
         } else {
             $template->hideBlock('upgradable');
         }
     }
 }
开发者ID:Cloudrexx,项目名称:cloudrexx,代码行数:33,代码来源:LicenseManager.class.php


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