本文整理汇总了PHP中Settings::getWebsiteName方法的典型用法代码示例。如果您正苦于以下问题:PHP Settings::getWebsiteName方法的具体用法?PHP Settings::getWebsiteName怎么用?PHP Settings::getWebsiteName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Settings
的用法示例。
在下文中一共展示了Settings::getWebsiteName方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: render
public function render()
{
getDisplay()->setTitle(Settings::getWebsiteName() . " - " . l("Error") . " " . $this->errorCode);
getDisplay()->setTemplateVariable("error_code", $this->errorCode);
getStyle()->run();
getDisplay()->add("header");
getDisplay()->add("error");
getDisplay()->add("footer");
getDisplay()->render();
}
示例2: toJS
public function toJS()
{
$generatedJS = ' $("#_orongo_ajax_comment_form").submit(function(event) {';
$generatedJS .= " event.preventDefault(); ";
$generatedJS .= " postComment('" . Settings::getWebsiteURL() . "ajax/postComment.php', " . $this->articleID . ", \$('textarea[name=_orongo_ajax_new_comment]').val(),'" . Settings::getWebsiteName() . "');";
$generatedJS .= " \$('textarea[name=_orongo_ajax_new_comment]').val('');";
$generatedJS .= " return false; ";
$generatedJS .= ' });';
return $generatedJS;
}
示例3: render
public function render()
{
getDisplay()->setTitle(Settings::getWebsiteName() . " - " . l("HOME"));
getDisplay()->setTemplateVariable("body", $this->body);
getDisplay()->setTemplateVariable("articles", $this->articleHTML);
getStyle()->run();
getDisplay()->add("header");
getDisplay()->add("index");
getDisplay()->add("footer");
getDisplay()->render();
}
示例4: render
public function render()
{
getDisplay()->setTitle(Settings::getWebsiteName() . " - " . $this->page->getTitle());
getDisplay()->setTemplateVariable("body", $this->body);
getDisplay()->setTemplateVariable("page", $this->page);
getStyle()->run();
getDisplay()->add("header");
getDisplay()->add("page");
getDisplay()->add("footer");
getDisplay()->render();
}
示例5: render
public function render()
{
getDisplay()->setTitle(Settings::getWebsiteName() . " - " . $this->article->getTitle());
getDisplay()->setTemplateVariable("body", $this->body);
getDisplay()->addHTML('<meta name="keywords" content="' . $this->article->getTagsString() . '"/>', 'head');
getDisplay()->setTemplateVariable("article", $this->article);
getDisplay()->setTemplateVariable("comments", $this->commentHTML);
getStyle()->run();
getDisplay()->add("header");
getDisplay()->add("article");
getDisplay()->add("footer");
getDisplay()->render();
}
示例6: generateActivationEmail
/**
* Generates an activation email
* @param String $paramUserName Name of the user
* @param String $paramActivationURL Activation URL
* @return array Generated Email
*/
public static function generateActivationEmail($paramUserName, $paramActivationURL)
{
$websiteName = Settings::getWebsiteName();
$msgArray = array();
$msgArray['subject'] = $websiteName . ' - Activate your account';
$msgArray['message'] = $paramUserName . ',
Thank you for registering at ' . $websiteName . '
In order to activate your new account please visit this URL:
' . $paramActivationURL . '
';
$msgArray['headers'] = 'From: ' . $websiteName . ' <' . Settings::getEmail() . '>';
return $msgArray;
}
示例7: startOrongo
require '../startOrongo.php';
startOrongo();
setCurrentPage('admin_orongo-settings');
Security::promptAuth();
if (getUser()->getRank() != RANK_ADMIN) {
header("Location: " . orongoURL("orongo-admin/index.php?msg=0"));
exit;
}
if (!isset($_POST['website_url']) || !isset($_POST['website_style']) || !isset($_POST['website_name']) || !isset($_POST['website_lang']) || !isset($_POST['show_archive'])) {
header("Location: " . orongoURL("orongo-admin/orongo-settings.php"));
exit;
}
if (Settings::getWebsiteURL() != $_POST['website_url'] && !empty($_POST['website_url'])) {
Settings::setWebsiteURL($_POST['website_url']);
}
if (Settings::getWebsiteName() != $_POST['website_name'] && !empty($_POST['website_name'])) {
Settings::setWebsiteName($_POST['website_name']);
}
if (Settings::getLanguageName() != $_POST['website_lang'] && !empty($_POST['website_lang'])) {
Settings::setLanguageName($_POST['website_lang']);
}
if (strval(Settings::showArchive()) != $_POST['show_archive'] && !empty($_POST['show_archive'])) {
Settings::setShowArchive($_POST['show_archive']);
}
if (getStyle()->getStyleFolder() != $_POST['website_style'] && file_exists(ROOT . "/themes/" . $_POST['website_style']) . "/info.xml") {
try {
Settings::setStyle($_POST['website_style']);
} catch (Exception $e) {
$msgbox = new MessageBox("Can't install style: " . $_POST['website_style']);
$msgbox->bindException($e);
die($msgbox->getImports() . $msgbox->toHTML());
示例8: render
public function render()
{
getDisplay()->setTitle(Settings::getWebsiteName() . " - " . $this->pageTitle);
getDisplay()->setTemplateVariable("body", $this->body);
if (count($this->msgs) > 0) {
$msgstring = "";
foreach ($this->msgs as $msg) {
if (!is_array($msg)) {
continue;
}
$msgstring .= '<h4 class="alert_' . $msg['msgtype'] . '">' . $msg['msg'] . "</h4>";
}
getDisplay()->setTemplateVariable("msgs", $msgstring);
}
$objectshtml = "";
foreach ($this->objects as $object) {
if ($object instanceof AdminFrontendObject == false) {
continue;
}
$objectshtml .= $object->toHTML();
}
getDisplay()->setTemplateVariable("objects", $objectshtml);
getDisplay()->setTemplateVariable("current_page", $this->pageTitle);
getDisplay()->setTemplateVariable("style_url", Settings::getWebsiteURL() . "orongo-admin/theme/");
getStyle()->run();
getDisplay()->add("header");
getDisplay()->add($this->pageTemplate);
getDisplay()->render();
}
示例9: render
/**
* Renders the Display
*/
public function render()
{
if ($this->rendered) {
return;
}
$this->setTemplateVariable("website_name", Settings::getWebsiteName());
$this->setTemplateVariable("website_url", Settings::getWebsiteURL());
$this->setTemplateVariable("version", "r" . REVISION);
$this->setTemplateVariable("menu", getMenu()->toHTML());
if (getUser() != null) {
$this->setTemplateVariable("user", getUser());
$on = new OrongoNotifier();
$on->start();
}
if (!$this->isImported(orongoURL('orongo-admin/theme/smoothness/jquery-ui-1.8.16.custom.css'))) {
$this->import(orongoURL('orongo-admin/theme/smoothness/jquery-ui-1.8.16.custom.css'));
}
if (!$this->isImported('https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js')) {
$this->import('https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js');
}
foreach ($this->objects as $object) {
if ($object == null) {
continue;
}
if ($object instanceof OrongoDisplayableObject == false) {
continue;
}
$this->addToTemplateVariable("body", $object->toHTML());
}
foreach ($this->imports as $import) {
$type = strrev($import);
$type = explode(".", $type);
$type = strrev($type[0]);
if (stristr($type, "?")) {
$type = explode("?", $type);
$type = $type[0];
}
switch ($type) {
case "css":
$this->addHTML('<link rel="stylesheet" href="' . $import . '" type="text/css" media="screen" />', "head");
break;
case "js":
$this->addHTML('<script type="text/javascript" src="' . $import . '"></script>', "head");
break;
default:
break;
}
}
$this->addToTemplateVariable("head", $this->head);
$this->addToTemplateVariable("body", $this->generalhtml);
foreach ($this->pluginhtml as $field => $html) {
$this->setTemplateVariable($field, $html);
}
$this->addToTemplateVariable("body", '<script type="text/javascript">' . $this->js . '</script>');
foreach ($this->tpls as $tpl) {
if (empty($tpl)) {
continue;
}
if (function_exists("getCurrentPage") && !stristr(getCurrentPage(), "admin") && !file_exists(raintpl::$tpl_dir . $tpl . ".html")) {
$msgbox = new MessageBox("Style was missing a file: " . $tpl . ".html");
die($msgbox->getImports() . $msgbox->toHTML());
}
$this->raintpl->draw($tpl);
}
$this->rendered = true;
}
示例10: header
if (getUser()->getRank() != RANK_ADMIN) {
header("Location: " . orongoURL("orongo-admin/index.php?msg=0"));
exit;
}
$settings = new AdminFrontend();
if (isset($_GET['msg'])) {
switch ($_GET['msg']) {
case 0:
$settings->addMessage(l("Settings saved"), "success");
default:
break;
}
}
$settings->main(array('time' => time(), 'page_title' => 'Orongo Settings', 'page_template' => 'dashboard'));
$settingForm = new AdminFrontendForm(100, "Orongo Settings", "POST", orongoURL("actions/action_SaveOrongoSettings.php"));
$settingForm->addInput("Website Name", "website_name", "text", Settings::getWebsiteName());
$settingForm->addInput("Website URL", "website_url", "text", Settings::getWebsiteURL());
$settingForm->addInput("Admin Email", "admin_email", "text", Settings::getEmail());
$currentShowArchiveString = Settings::showArchive() ? l("Yes") : l("No");
$settingForm->addRadios("Show archive", "show_archive", array(l("Yes") => "true", l("No") => "false"), $currentShowArchiveString);
$languages = array(Settings::getLanguageName() => "nl_NL");
$files = @scandir(ADMIN . '/lang/');
if (is_array($files)) {
foreach ($files as $file) {
if ($file == Settings::getLanguageName() || stristr($file, ".")) {
continue;
}
$languages[$file] = $file;
}
}
$styles = array(getStyle()->getStyleName() => getStyle()->getStyleFolder());