本文整理匯總了PHP中core\Config::Write方法的典型用法代碼示例。如果您正苦於以下問題:PHP Config::Write方法的具體用法?PHP Config::Write怎麽用?PHP Config::Write使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類core\Config
的用法示例。
在下文中一共展示了Config::Write方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: getUrl
private function getUrl()
{
$url = isset($_GET["url"]) ? $_GET["url"] : "";
unset($_GET["url"]);
$url = explode("/", trim($url, "/"), 3);
if (count($url) > 0) {
$url[0] = str_replace(" ", "", ucwords($url[0]));
Config::Write("control", ($url[0] != "" ? $url[0] : "Index") . "Control");
Config::Write("function", isset($url[1]) ? str_replace(" ", "", $url[1]) : "index");
Config::Write("parametros", isset($url[2]) ? $url[2] : "");
}
}
示例2: array
<?php
use Core\Config;
Config::Write("CACHE", false);
Config::Write("BD_HOST", "localhost");
Config::Write("BD_NAME", "erp");
Config::Write("BD_USER", "root");
Config::Write("BD_PASS", "bm9ybWFu");
Config::Write("BD_DRIVE", "mysql");
Config::Write('control', "indexControl");
Config::Write('function', "index");
Config::Write('parametros', '');
/***** Selección de plantillas *****/
Config::Write("FPLANTILLA", "boot");
Config::Write("Admin", "admin");
Config::Write("Page", array("panel" => "cliente"));
Config::Write("IMG", array("images", "banners"));
Config::Write("SESSION", "MANAGER");
Config::Write("Formatos", array("image/png", "image/pjpeg", "image/jpg", "image/jpeg", "image/gif"));
Config::Write("SizeImage", array("Logo" => 2));
Config::Write("DimImage", array("Logo" => array(250, 250)));
Config::Write("SALT", "secret");