插件代码上传
This commit is contained in:
12
plugin/grey/grey.css
Normal file
12
plugin/grey/grey.css
Normal file
@@ -0,0 +1,12 @@
|
||||
@charset "utf-8";
|
||||
/* CSS Document 使整个网站变成灰色 */
|
||||
|
||||
html{
|
||||
filter:progid:DXImageTransform.Microsoft.BasicImage(grayscale=1);
|
||||
-webkit-filter: grayscale(100%);
|
||||
-moz-filter: grayscale(100%);
|
||||
-ms-filter: grayscale(100%);
|
||||
-o-filter: grayscale(100%);
|
||||
filter: grayscale(100%);
|
||||
filter: gray;
|
||||
}
|
6
plugin/grey/include.php
Normal file
6
plugin/grey/include.php
Normal file
@@ -0,0 +1,6 @@
|
||||
<?php
|
||||
function zxd_ctrlcenter_grey(){
|
||||
global $zbp;
|
||||
$zbp->header .= '<link href="'.$zbp->host.'zb_users/plugin/zxd_ctrlcenter/plugin/grey/grey.css" rel="stylesheet" type="text/css" />
|
||||
' . "\r\n";
|
||||
}
|
BIN
plugin/grey/logo.png
Normal file
BIN
plugin/grey/logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
3
plugin/grey/manage/config.php
Normal file
3
plugin/grey/manage/config.php
Normal file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
$PluginTitle = "网站变灰(适合清明节用)";
|
||||
$PluginShortTitle = "网站变灰";
|
33
plugin/grey/manage/status.php
Normal file
33
plugin/grey/manage/status.php
Normal file
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
if(!empty($_GET['include'])&&$_GET['include']=="c_system_base"){
|
||||
// 单独打开时需要引入这个,不然$zbp未定义
|
||||
include_once '../../../../../../zb_system/function/c_system_base.php';
|
||||
}
|
||||
|
||||
global $zbp;
|
||||
if(empty($_GET['action']))
|
||||
$status_action = "";
|
||||
else
|
||||
$status_action = $_GET['action'];
|
||||
|
||||
$Close = '<script>window.close(); window.opener.location.reload(); </script>';
|
||||
switch ($status_action) {
|
||||
case 'chk':
|
||||
$pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_grey_Enable;
|
||||
break;
|
||||
case 'enb':
|
||||
$zbp->Config('zxd_ctrlcenter')-> plugin_grey_Enable = true;
|
||||
$zbp->SaveConfig('zxd_ctrlcenter');
|
||||
echo $Close;
|
||||
break;
|
||||
case 'dis':
|
||||
$zbp->Config('zxd_ctrlcenter')-> plugin_grey_Enable = false;
|
||||
$zbp->SaveConfig('zxd_ctrlcenter');
|
||||
echo $Close;
|
||||
break;
|
||||
|
||||
default:
|
||||
$pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_grey_Enable;
|
||||
break;
|
||||
}
|
||||
?>
|
38
plugin/grey/plugin.xml
Normal file
38
plugin/grey/plugin.xml
Normal file
@@ -0,0 +1,38 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<plugin version="php">
|
||||
<id>xd_gray</id>
|
||||
<name>整站变灰</name>
|
||||
<url></url>
|
||||
<note>整站变灰</note>
|
||||
<description>整站变灰</description>
|
||||
<path></path>
|
||||
<include>include.php</include>
|
||||
<level>1</level>
|
||||
<author>
|
||||
<name>xiandan</name>
|
||||
<email></email>
|
||||
<url></url>
|
||||
</author>
|
||||
<source>
|
||||
<name></name>
|
||||
<email></email>
|
||||
<url></url>
|
||||
</source>
|
||||
<adapted>151626</adapted>
|
||||
<version>1.0</version>
|
||||
<pubdate>2017-02-01</pubdate>
|
||||
<modified>2017-02-05</modified>
|
||||
<price>0</price>
|
||||
<advanced>
|
||||
<dependency></dependency>
|
||||
<rewritefunctions></rewritefunctions>
|
||||
<conflict></conflict>
|
||||
</advanced>
|
||||
<sidebars>
|
||||
<sidebar1></sidebar1>
|
||||
<sidebar2></sidebar2>
|
||||
<sidebar3></sidebar3>
|
||||
<sidebar4></sidebar4>
|
||||
<sidebar5></sidebar5>
|
||||
</sidebars>
|
||||
</plugin>
|
Reference in New Issue
Block a user