From 3be967b672ec97e0511f7f88df0e33ae78a461bc Mon Sep 17 00:00:00 2001 From: printempw Date: Sat, 19 Mar 2016 15:35:16 +0800 Subject: [PATCH] added option home_pic_url --- admin/customize.php | 33 +++++++++++++++++++++++++++++++-- admin/install.php | 5 +++-- assets/css/index.style.css | 5 +---- index.php | 7 ++++++- 4 files changed, 41 insertions(+), 9 deletions(-) diff --git a/admin/customize.php b/admin/customize.php index 10066d6a..b62fac26 100644 --- a/admin/customize.php +++ b/admin/customize.php @@ -3,7 +3,7 @@ * @Author: printempw * @Date: 2016-03-19 14:34:21 * @Last Modified by: printempw - * @Last Modified time: 2016-03-19 15:06:36 + * @Last Modified time: 2016-03-19 15:31:15 */ require "../includes/session.inc.php"; if (!$user->is_admin) header('Location: ../index.php?msg=看起来你并不是管理员'); @@ -33,7 +33,7 @@ $db = new Database\Database();
-
+

更改配色

@@ -99,6 +99,35 @@ $db = new Database\Database();
+
+
+

首页配置

+
+
+ +
+ 设置已保存。
'; + } ?> + + + + + + + + +
首页图片地址 + +
+
+ + +
diff --git a/admin/install.php b/admin/install.php index f071fddf..c4355f79 100644 --- a/admin/install.php +++ b/admin/install.php @@ -3,7 +3,7 @@ * @Author: printempw * @Date: 2016-01-16 23:01:33 * @Last Modified by: printempw - * @Last Modified time: 2016-03-19 15:20:18 + * @Last Modified time: 2016-03-19 15:34:26 * * Blessing Skin Server Installer */ @@ -189,7 +189,8 @@ $sql3 = "INSERT INTO `$table_options` (`option_id`, `option_name`, `option_val (10, 'data_column_uname', 'username'), (11, 'data_column_passwd', 'password'), (12, 'data_column_ip', 'ip'), - (12, 'color_scheme', 'skin-blue');"; + (12, 'color_scheme', 'skin-blue'), + (14, 'home_pic_url', './assets/images/bg.jpg');"; if (!$conn->query($sql1) || !$conn->query($sql2) || !$conn->query($sql3)) { ?>

数据表创建失败

diff --git a/assets/css/index.style.css b/assets/css/index.style.css index 17b4c587..83ec7b35 100644 --- a/assets/css/index.style.css +++ b/assets/css/index.style.css @@ -2,7 +2,7 @@ * @Author: printempw * @Date: 2016-01-21 20:07:47 * @Last Modified by: printempw -* @Last Modified time: 2016-03-19 10:08:29 +* @Last Modified time: 2016-03-19 15:33:10 */ .home-menu-blur { position: absolute; @@ -17,7 +17,6 @@ background-color: rgba(255,255,255,0.4); } .home-menu-bg { - background-image: url("../images/bg.jpg"); background-position: center 0; background-size: auto 800px; position: absolute; @@ -33,8 +32,6 @@ } .container { - background-image: - url("../images/bg.jpg"); background-size: auto 800px; background-repeat: no-repeat; background-position: center 0; diff --git a/index.php b/index.php index 876426be..f5c6c51a 100755 --- a/index.php +++ b/index.php @@ -3,7 +3,7 @@ * @Author: printempw * @Date: 2016-01-17 13:55:20 * @Last Modified by: printempw - * @Last Modified time: 2016-03-18 17:47:57 + * @Last Modified time: 2016-03-19 15:33:43 */ session_start(); $dir = dirname(__FILE__); @@ -33,6 +33,11 @@ if (isset($_COOKIE['uname']) && isset($_COOKIE['token'])) { +