本文整理汇总了PHP中Server::DefineURL方法的典型用法代码示例。如果您正苦于以下问题:PHP Server::DefineURL方法的具体用法?PHP Server::DefineURL怎么用?PHP Server::DefineURL使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server
的用法示例。
在下文中一共展示了Server::DefineURL方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: define
* Improper changes to this file may cause critical errors.
***************************************************************************************/
define("IN_LIVEZILLA", true);
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
@ini_set('session.use_cookies', '0');
@error_reporting(E_ALL);
$html = "";
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_lib/functions.external.inc.php";
require LIVEZILLA_PATH . "_lib/objects.external.inc.php";
Server::DefineURL(FILE_CHAT);
Server::InitDataProvider();
LocalizationManager::AutoLoad();
$browserId = getId(USER_ID_LENGTH);
if (!isset($_GET[GET_EXTERN_TEMPLATE])) {
@set_time_limit(Server::$Configuration->File["timeout_chats"]);
if (!isset($_GET["file"])) {
@set_error_handler("handleError");
}
define("SESSION", getSessionId());
if (empty(Server::$Configuration->File["gl_om_pop_up"]) && Server::$Configuration->File["gl_om_mode"] == 1) {
Server::InitDataBlock(array("INTERNAL", "GROUPS", "FILTERS"));
$groupbuilder = new GroupBuilder();
$groupbuilder->Generate();
if (!$groupbuilder->GroupAvailable) {
exit("<html><script language=\"JavaScript\">if(typeof(window.opener != null) != 'undefined')window.opener.location = \"" . Server::$Configuration->File["gl_om_http"] . "\";window.close();</script></html>");
示例2: define
* Copyright 2015 LiveZilla GmbH
* All rights reserved.
* LiveZilla is a registered trademark.
*
* Improper changes to this file may cause critical errors.
***************************************************************************************/
define("IN_LIVEZILLA", true);
header('Content-Type: text/html; charset=utf-8');
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
Server::DefineURL("print.php");
@set_error_handler("handleError");
if (Server::InitDataProvider()) {
if (!empty($_GET[GET_TRACK_CHATID]) && !empty($_GET[GET_TRACK_BROWSERID]) && !empty($_GET[GET_TRACK_USERID])) {
$archive = new Chat();
$archive->ChatId = intval(Communication::GetParameter("c", ""));
$archive->Load();
$chat = VisitorChat::GetByChatId($archive->ChatId);
if ($chat->BrowserId == Communication::GetParameter(GET_TRACK_BROWSERID, "") && $chat->UserId == Communication::GetParameter(GET_TRACK_USERID, "") && $chat->LastActive > time() - 3600) {
$print = IOStruct::GetFile(PATH_TEMPLATES . "print.tpl");
$archive->Generate($archive->ChatId, "", true, true);
$print = str_replace("<!--chat_id-->", $archive->ChatId, $print);
$print = str_replace("<!--transcript-->", nl2br($archive->PlainText), $print);
}
exit($print);
}
示例3: define
/****************************************************************************************
* LiveZilla report.php
*
* Copyright 2014 LiveZilla GmbH
* All rights reserved.
* LiveZilla is a registered trademark.
*
* Improper changes to this file may cause critical errors.
***************************************************************************************/
define("IN_LIVEZILLA", true);
header('Content-Type: text/html; charset=utf-8');
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
@set_error_handler("handleError");
if (!empty($_GET["h"]) && !empty($_GET["y"]) && isset($_GET["m"]) && isset($_GET["d"]) && Server::InitDataProvider()) {
Server::DefineURL("report.php");
Server::InitStatisticProvider();
$repData = StatisticProvider::GetReportFromHash($_GET["h"], $_GET["y"], $_GET["m"], $_GET["d"], !empty($_GET["u"]));
if ($repData !== false) {
LocalizationManager::AutoLoad(strtolower(Server::$Configuration->File["gl_default_language"]), true);
$repData = Server::Replace($repData, true, false, false, true);
exit($repData);
}
}
exit("Sorry, report was not found.");
示例4: define
* Improper changes to this file may cause critical errors.
***************************************************************************************/
if (isset($_GET["id"])) {
define("IN_LIVEZILLA", true);
header('Content-Type: text/html; charset=utf-8');
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_lib/functions.external.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
@set_error_handler("handleError");
Server::InitDataProvider();
Server::DefineURL("knowledgebase.php");
LocalizationManager::AutoLoad();
$color = ExternalChat::ReadTextColor();
$entry = KnowledgeBaseEntry::GetById(Communication::ReadParameter("id", ""), true);
if (!empty($entry)) {
$html = IOStruct::GetFile(PATH_TEMPLATES . "kb_entry.tpl");
if (!empty(Server::$Configuration->File["gl_kcss"])) {
$html = str_replace("<!--custom_css-->", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" . Server::$Configuration->File["gl_kcss"] . "\">", $html);
}
if (Server::$Configuration->File["gl_knbr"]) {
$rresult = $entry->GetRateResult();
if (($rate = Communication::ReadParameter("h", -1)) != -1) {
$html = str_replace("<!--rate_text-->", "<br><div id=\"lz_chat_dialog_kb_rate\">" . $LZLANG["client_feedback_success"] . "</div>", $html);
$entry->SaveRateResult($rate);
} else {
$bhtml = "<a href=\"./knowledgebase.php?id=<!--id-->&h=MQ__\"><!--lang_client_yes--></a><a href=\"./knowledgebase.php?id=<!--id-->&h=MA__\"><!--lang_client_no--></a>";
示例5: define
***************************************************************************************/
define("IN_LIVEZILLA", true);
define("IN_API", true);
define("LIVEZILLA_PATH", "../../");
@set_time_limit(30);
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
require LIVEZILLA_PATH . "_lib/objects.internal.inc.php";
@set_error_handler("handleError");
@error_reporting(E_ALL);
header("Pragma: no-cache");
header("Cache-Control: no-cache, must-revalidate");
header("Keep-Alive: timeout=5, max=100");
Server::DefineURL("api.php");
Server::InitDataProvider();
Server::InitDataBlock(array("INTERNAL", "INPUTS", "DBCONFIG"));
OperatorRequest::Validate(true);
if (OperatorRequest::IsValidated() && Is::Defined("CALLER_SYSTEM_ID")) {
if (Server::$Operators[CALLER_SYSTEM_ID]->GetPermission(46) != PERMISSION_NONE) {
require "objects.apiv2.inc.php";
$apiv2 = new ApiV2(isset($_POST["p_json_pretty"]));
if ($apiv2->RunActions() && empty($apiv2->ErrorField) && !empty($apiv2->JSONOutput)) {
exit($apiv2->JSONOutput);
} else {
APIErrorExit($apiv2->GetErrorCodes());
}
} else {
APIErrorExit("LZAV20002");
}
示例6: define
***************************************************************************************/
define("IN_LIVEZILLA", true);
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
header("Content-Type: text/html; charset=UTF-8");
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_lib/functions.index.inc.php";
CacheManager::Flush();
LocalizationManager::AutoLoad();
@set_error_handler("handleError");
Server::InitDataProvider();
Server::DefineURL("index.php");
$scheme = Communication::GetScheme();
$html = IOStruct::GetFile(TEMPLATE_HTML_INDEX);
$errorbox = null;
$errors['write'] = getFolderPermissions();
$errors['php_version'] = getPhpVersion();
$errors['mysql'] = getMySQL();
$errors['disabled'] = getDisabledFunctions();
if (!empty($errors['write']) || !empty($errors['php_version']) || !empty($errors['mysql']) || !empty($errors['disabled'])) {
$errorbox = IOStruct::GetFile(TEMPLATE_HTML_INDEX_ERRORS);
$errorbox = str_replace("<!--write_access-->", $errors['write'], $errorbox);
if (strlen($errors['write']) > 0 && !empty($errors['php_version'])) {
$errors['php_version'] = "<br><br>" . $errors['php_version'];
}
if ((strlen($errors['write']) > 0 || !empty($errors['php_version'])) && !empty($errors['mysql'])) {
$errors['mysql'] = "<br><br>" . $errors['mysql'];
示例7: define
*
* Improper changes to this file may cause critical errors.
***************************************************************************************/
define("IN_LIVEZILLA", true);
define("SAFE_MODE", @ini_get('safe_mode'));
define("LIVEZILLA_PATH", "./");
@error_reporting(E_ALL);
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_lib/objects.devices.inc.php";
define("ACCESSTIME", SystemTime::GetRuntime());
if (Server::IsServerSetup()) {
CacheManager::Flush();
}
Server::DefineURL(FILE_SERVER_FILE);
Operator::PrepareConnection();
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
Server::InitDataProvider();
Server::SetTimeLimit(Server::$Configuration->File["timeout_clients"]);
@ini_set('session.use_cookies', '0');
if (DEBUG_MODE) {
@ini_set('display_errors', '1');
}
@set_error_handler("handleError");
header("Access-Control-Allow-Origin: *");
$getRequest = Communication::GetParameterAlias("rqst");
if (isset($_POST[POST_INTERN_REQUEST]) || !empty($getRequest)) {
if (DB_CONNECTION && STATS_ACTIVE) {
Server::InitStatisticProvider();
}
示例8: define
*
* Copyright 2014 LiveZilla GmbH
* All rights reserved.
* LiveZilla is a registered trademark.
*
* Improper changes to this file may cause critical errors.
***************************************************************************************/
define("IN_LIVEZILLA", true);
if (!defined("LIVEZILLA_PATH")) {
define("LIVEZILLA_PATH", "./");
}
require LIVEZILLA_PATH . "_definitions/definitions.inc.php";
require LIVEZILLA_PATH . "_lib/functions.global.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.dynamic.inc.php";
require LIVEZILLA_PATH . "_definitions/definitions.protocol.inc.php";
Server::DefineURL("checkout.php");
@set_error_handler("handleError");
Server::InitDataProvider();
Server::InitDataBlock(array("DBCONFIG"));
if (!empty($_POST["form_visitor_id"]) && !empty($_POST["form_total_price"]) && !empty($_POST["form_currency"]) && is_numeric($_POST["form_total_price"]) && strlen($_POST["form_currency"]) <= 3) {
LocalizationManager::AutoLoad();
$ticket = new CommercialChatVoucher($_POST["form_voucher_type"], strtoupper(getId(16)));
$ticket->VisitorId = $_POST["form_visitor_id"];
$ticket->Company = $_POST["form_company"];
$ticket->Email = $_POST["form_email"];
$ticket->Firstname = $_POST["form_firstname"];
$ticket->Lastname = $_POST["form_lastname"];
$ticket->Address1 = $_POST["form_address_1"];
$ticket->Address2 = $_POST["form_address_2"];
$ticket->ZIP = $_POST["form_zip"];
$ticket->State = $_POST["form_state"];