本文整理汇总了PHP中system::settings方法的典型用法代码示例。如果您正苦于以下问题:PHP system::settings方法的具体用法?PHP system::settings怎么用?PHP system::settings使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类system
的用法示例。
在下文中一共展示了system::settings方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: system
$system = new system();
$settings = $system->settings();
?>
<div>
<h3>Systemeinstellungen</h3>
<p>Hier kannst du alle Einstellungen deines Systemes vornehmen.</p>
<br>
<?php
$s = new system();
$site_settings = $s->settings();
if (isset($_POST['submit'])) {
$mysqli = new connection();
if (isset($_POST['startpage'])) {
$startpage = $_POST['startpage'];
$delete_frontpage = new connection();
$delete_frontpage->query("UPDATE object SET startpage=0 WHERE startpage=1");
$update_frontpage = new connection();
$update_frontpage->query("UPDATE object SET startpage=1 WHERE id={$startpage}");
}
if (!empty($_POST['site_name'])) {
$new_sitename = htmlentities($_POST['site_name']);
$mysqli->query("UPDATE settings SET value='{$new_sitename}' WHERE settings.key = 'site_name'");
}
if (!empty($_POST['site_keywords'])) {
$new_site_keywords = htmlentities($_POST['site_keywords']);
示例2: system
<?php
//header("Content-Type: text/html; charset=utf-8");
error_reporting(0);
date_default_timezone_set('Europe/Berlin');
include "../ping.php";
include "auth.php";
include "../system/classes/class_connection.php";
include "../system/classes/class_system.php";
$system = new system();
$settings = $system->settings();
$page = NULL;
if (isset($_GET['page'])) {
$page = $_GET['page'];
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Adminpanel</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no" />
<link href="../content/themes/<?php
if (null !== $settings['site_theme']) {
echo $settings['site_theme'];
} else {
echo "default";
}
?>
/css/style.css" rel="stylesheet" type="text/css" />