$cur_key = $new_key; if (@kConf::get('replace_passwords') === true) { if (file_exists(dirname(__FILE__) . '/replace.php')) { include_once dirname(__FILE__) . '/replace.php'; } } } else { $cur_key = kConf::get('kaltura_activation_key'); } if ($installation_type == 'CE') { $status_div = getUnlimited(); } else { if (!$cur_key) { $status_div = getNoKey(); } else { $days_to_expire = ActKeyUtils::daysToExpire($cur_key); if ($days_to_expire === false) { $status_div = getExpired(); } else { if ($days_to_expire === true) { $status_div = getUnlimited(); } else { $status_div = getNormal($days_to_expire); } } } } //-----FUNCTIONS -------------------------------------------------------------- function getNormal($days) { return '<div id="status_normal class="passed">
<?php $start = microtime(true); require_once dirname(__FILE__) . '/../../alpha/config/sfrootdir.php'; // check cache before loading anything require_once "../lib/KalturaResponseCacher.php"; $cache = new KalturaResponseCacher(); $cache->checkOrStart(); require_once "../bootstrap.php"; ActKeyUtils::checkCurrent(); KalturaLog::setContext("API"); KalturaLog::debug(">------------------------------------- api_v3 -------------------------------------"); KalturaLog::info("API-start "); $controller = KalturaFrontController::getInstance(); $controller->run(); $end = microtime(true); KalturaLog::info("API-end [" . ($end - $start) . "]"); KalturaLog::debug("<------------------------------------- api_v3 -------------------------------------"); $cache->end();
public static function checkCurrent() { $cur_key = kConf::get('kaltura_activation_key'); if ($cur_key == false) { $not_activated_msg = "Thank you for using the Kaltura On-Prem Video Platform.\n\r\nTo start your evaluation please activate your evaluation package from within the \"http://" . kConf::get('apphome_url_no_protocol') . "/start page\".<br/>\r\nFor support, please contact the Kaltura technical presales team."; die($not_activated_msg); } $result = ActKeyUtils::daysToExpire($cur_key); if ($result == false) { $expired_msg = "Thank you for using the Kaltura On-Prem Video Platform.<br/>\r\nYour evaluation period has ended. Please contact Kaltura sales for transition to a permanent license"; die($expired_msg); } }