commit 86848dbde0f4926950f99eb8a0c433fa71bbbcc3 Author: Coding Zhang <2291200076@qq.com> Date: Wed Jan 26 02:20:35 2022 +0800 插件代码上传 diff --git a/about/BUYER NOTICE.htm b/about/BUYER NOTICE.htm new file mode 100644 index 0000000..2ac4e8d --- /dev/null +++ b/about/BUYER NOTICE.htm @@ -0,0 +1,34 @@ + + + + +

+ 购买须知:请仔细阅读后再决定是否购买本插件! +

+
    +
  1. 本插件原则上不提供售后服务。您购买本插件不代表我们会提供一对一服务;也不代表我们会对您使用插件的后果承担责任。
  2. +
  3. 代码经过加密混淆,即使您购买,也无法获取源码。
  4. +
  5. 您购买本插件,需要遵守相关规则,只有在您购买的账户下可下载本插件。
  6. +
  7. 购买本插件,仅代表您有拥有插件的使用权,您无权将插件分享给他人,或通过技术手段对插件所包含任意文件(特别是插件的版权信息)进行修改或删除,或在应用商店中以“收费”插件的形式再次发布本插件相关代码(即您不可通过本插件代码获得任何收益)。
  8. +
  9. 本插件属于特殊商品,已经购买概不退货,您已知晓并理解。
  10. +
+

+ 为什么不提供售后? +

+

+ 说实话,做插件真的不赚钱!真的不赚钱!做插件所投入的时间成本远不止这一点钱可以换来的!设置收费只是希望下载的站长们能够善用这款插件。所以本插件原则上不提供售后服务,但在我能力范围内的问题,我有空时一般都会解答。 +

+

+ 购买后,支持本插件后续免费升级新版本(如果有)。如果您不愿意购买,请加张小弟之家粉丝群(可在https://only4.work/网站博客下方找到加群方式,点击“张小弟粉丝群”超链接即可加入)并私聊管理员,管理员将安装包单独发给你,但是不提供更新,想要使用新版本需要再次联系管理员。 +

+

+ 购买和不购买的区别: +

+ +

+
+

+ \ No newline at end of file diff --git a/about/readme.html b/about/readme.html new file mode 100644 index 0000000..838178f --- /dev/null +++ b/about/readme.html @@ -0,0 +1,305 @@ + + + + + +

+ 特别注意:使用前一定要备份网站,在镜像站中调试确认可用后再部署至主站点上,一定要不要直接在主站点上使用!因使用本插件造成的网站数据丢失或损坏,或其他任何后果,插件作者不承担任何责任,望知晓。介意勿用!下载使用本插件即视为您已阅读并同意本条款。 +

+

+
+

+
+

+
+

+

+ 很高兴你能选择这款插件。这款插件是由张小弟之家综合Z-BlogPHP应用商店中多个免费应用并加以改进优化而成,集多种zblog网站小工具于一身,且不断更新中。 +

+

+ 目前,这个插件还在测试之中,功能很少,后期会不断更新出更多功能,敬请期待! +

+

+ 使用本插件前,请仔细阅读本说明,说明中写明的请不要再问,节约彼此时间,谢谢! +

+

+
+

+
+

+
+

+

+ What's new? +

+

+ -- 2020/08/20 -- 1.1.1 -------------------------- +

+

+     更新后请关闭插件再开启一次,以完全加载新功能模块。 +

+

+     综合了【流年岁月】的【来访蜘蛛统计】插件,增加CSRF防护,更安全。 +

+

+     增加了“清除设置”功能。 +

+

+     完善了关于页面,更新了截图,增加了彻底卸载本插件的方法。 +

+

+ -------------------------------------------------- +

+

+
+

+

+ 现有功能: +

+

+ 指定文章不存在时,404跳转 +

+

+ 网站变灰(清明节用) +

+

+ 代码高亮 +

+

+ 微信打赏二维码 +

+

+ 搜索引擎蜘蛛来访统计 +

+

+ 更多功能开发中,后期会通过插件更新加入新功能,敬请期待... +

+

+
+

+
+

+
+

+

+

+ 插件开发环境:Z-BlogPHP 1.6.4.2135 (Valyria) +

+

+ 数据库:MySQL (字符集:UTF-8) +

+

+ 系统环境:Linux2.6.32; Apache; +

+

+ PHP版本:PHP7.1.3x64; +

+

+ (因为实际环境多种多样,我们无法保证所有环境均可兼容,如果该插件与您使用的环境不兼容,可通过邮箱告知我) +

+

+
+

+

+ 最低要求环境:Z-BlogPHP 1.6.4.2135 (Valyria) +

+

+ 数据库:MySQL +

+

+ PHP:5.4及以上版本 +

+

+ 浏览器:建议使用Google或Firefox内核浏览器。使用IE内核将不能获得良好使用体验甚至不能正常使用。
+     测试可用:新版Edge浏览器、最新版firefox浏览器、QQ浏览器极速内核;
+     理论支持:谷歌浏览器;
+     不完美支持:QQ浏览器兼容内核、旧版Edge浏览器(可用,但是由于内核原因有小Bug);
+     不支持:IE浏览器、手机浏览器(包括设置电脑版的情况) +

+

+
+

+

+ 经测试,确定不可用环境:(该插件不支持此环境,且未来也不会支持此环境,请换用其他插件,谢谢)
ASP版本Z-Blog;非MySQL数据库类型(部分子插件不支持SQLite,安装后可能会出现问题);PHP5.3以下版本;上古版本Z-Blog +

+

+
+

+
+

+
+

+

+ 问题解答 & 下载前须知: +

+

+ 为什么要把这些插件综合起来呢? +

+

+     事实上,你完全可以从应用商店里单独下载每一个插件并按需使用。但是这样的话如果装的插件比较多的话,插件管理列表中管理起来会不太方便,而且偶尔会出现两个插件互相不兼容的情况。但是我们将插件综合的过程中,已经测试好了,在本插件内使用多个功能是互不影响互不冲突的。 +

+

+
+

+

+ 我可以同时使用被本插件综合的插件和本插件吗? +

+

+     这个我们没有测试过。理论上说应该可以,但是我们非常不建议这样做。因为这样做其实是完全没有必要的,使用其中任意一个就够了。您同时使用两个插件虽然在数据库中是互不影响的,但是在执行过程中相当于每个步骤都会被执行两次,可能会出现不可预料的后果。 +

+

+
+

+

+ 下载本插件后插件作者有义务提供售后服务吗? +

+

+     插件作者无义务为您提供免费的售后或者是咨询义务。出于职业道德,我们一般会回答您的问题,但同时我们也有权拒绝回答。若本插件后期变为收费插件,您的付费视作打赏。 +

+

+
+

+

+ 下载后发现插件用的不爽,可以在评论区刷屏吗? +

+

+     不能,如果本插件您用的不爽可以清除插件设置并卸载,请勿在评论区刷屏,扰乱整个应用市场的氛围。 +

+

+
+

+

+ 插件可以用作非法用途吗? +

+

+     本插件绝不允许使用在色情违法或擦边球等涉及到法律问题的网站上,对于这样的站点,本插件不欢迎你的使用,请立刻卸载本插件并关闭本页,谢谢合作。对于非法网站,插件作者拒绝回答任何问题,并上报中央网信办(中央网信办(国家互联网信息办公室)违法和不良信息举报中心,网址:https://www.12377.cn/)。 +

+

+
+

+

+ 插件后期会提供去除Z-Blog网页底部版权的功能吗? +

+

+     很抱歉,不会。如果您想去除网页底部版权信息,请购买zblog商业授权,链接:https://www.zblogcn.com/service/ +

+

+
+

+
+

+
+

+

+ 如何彻底卸载本插件? +

+

+ 1. 首先,在插件设置页面,点击右上角“清除设置”按钮,然后弹出的确认框点是,清空插件的配置信息。 +

+

+ 2. 然后,禁用插件并卸载。 +

+

+ 3. 最后,登录后台数据库,删除数据表【表前缀_zxd_ctrlcenter_spider】 +

+

+ 4. 卸载完成 +

+

+
+

+
+

+
+

+

+ 如果您有问题,有建议,有想法,都欢迎通过邮箱联系我。欢迎大家前来提提建议或者意见,我会努力不断优化改进本插件的。 +

+

+ 如果您是插件的开发者,我们集成了您的插件,但是你不希望你的插件被我们集成,请通过邮箱联系我(邮箱见下方),我们会在下一个版本中移除您的插件。 +

+

+
+

+
+

+
+

+

+ 本人现为在校大学生,初来乍到,虽然都是按照开发文档规范开发的,但是我不能保证插件兼容性和稳定性。限于本人能力有限,可能有很多你们问的问题我也不知道如何解决,还请多多理解!张小弟之家是我的个人网站。有兴趣可以来逛逛。内容比较杂,还请多多指正。 +

+

+
+

+

+ 联系方式: +

+

+ 联系邮箱:admin@mail.only4.work +

+

+ 备用邮箱:zhangxiaodi412@vip.qq.com +

+

+ 张小弟粉丝群:134702641(新创QQ群,人数较少) +

+

+
+

+
+

+ 后台截图: +

+ + +

+
+

+
+

+
+

+

+ 往期版本更新日志 +

+

+ -- 2020/07/12 -- 1.0.0 -------------------------- +

+

+     第一版横空出世! +

+

+     综合了【Thx】的【自定义404链接】插件 +

+

+     综合了【xiandan】的【整站变灰】插件 +

+

+     综合了【隔壁老李】的【野路子代码显示优化 Plus】插件 +

+

+     综合了【阿木林】的【微信打赏】插件 +

+

+     修改了几处相对路径问题,可支持非根目录下安装的 Z-Blog PHP 程序 +

+

+     对综合的插件均进行了改动优化,使之使用起来更加方便易用。 +

+

+     保留插件原作者的全部版权信息,在设置页最后可以很方便的查看! +

+

+ -------------------------------------------------- +

+

+
+

+ \ No newline at end of file diff --git a/config.php b/config.php new file mode 100644 index 0000000..132eed2 --- /dev/null +++ b/config.php @@ -0,0 +1,9 @@ +Config('zxd_ctrlcenter')->relativepath = 'zb_users/plugin/zxd_ctrlcenter/'; +$zbp->Config('zxd_ctrlcenter')->path = $blogpath.'zb_users/plugin/zxd_ctrlcenter/'; +$zbp->Config('zxd_ctrlcenter')->urlpath = $bloghost.'zb_users/plugin/zxd_ctrlcenter/'; + + +// $zbp->host \ No newline at end of file diff --git a/include.php b/include.php new file mode 100644 index 0000000..87a1b24 --- /dev/null +++ b/include.php @@ -0,0 +1,95 @@ +Config('zxd_ctrlcenter')-> plugin_404_Enable) + Add_Filter_Plugin('Filter_Plugin_Zbp_ShowError', 'zxd_ctrlcenter_404'); // 404 + if($zbp->Config('zxd_ctrlcenter')-> plugin_grey_Enable) + Add_Filter_Plugin('Filter_Plugin_Zbp_MakeTemplatetags','zxd_ctrlcenter_grey'); // 网站变黑 + if($zbp->Config('zxd_ctrlcenter')-> plugin_code_Enable) + Add_Filter_Plugin('Filter_Plugin_ViewPost_Template', 'zxd_ctrlcenter_code'); // 代码显示优化 + if($zbp->Config('zxd_ctrlcenter')-> plugin_wxreward_Enable) { + Add_Filter_Plugin('Filter_Plugin_Zbp_MakeTemplatetags','zxd_ctrlcenter_wxreward_js'); // 微信打赏 + Add_Filter_Plugin('Filter_Plugin_ViewPost_Template','zxd_ctrlcenter_wxreward_html'); + } + if($zbp->Config('zxd_ctrlcenter')-> plugin_spider_Enable){ + Add_Filter_Plugin('Filter_Plugin_Index_End','zxd_ctrlcenter_Index_End'); // 蜘蛛来访 抓取统计 + } + + // 判断表格是否存在在,如果不存在就创建表 + zxd_ctrlcenter_spider_CreateTable(); +} + +function InstallPlugin_zxd_ctrlcenter() { + // 蜘蛛来访 + global $zbp; + //配置初始化,判断是否是安装插件后第一次启动 + if (!$zbp->Config('zxd_ctrlcenter') -> HasKey('zxd_ctrlcenter_version')) { + $zbp->Config('zxd_ctrlcenter') -> zxd_ctrlcenter_version = '1.1.1'; + + $zbp->Config('zxd_ctrlcenter') -> plugin_spider_viewconut ='20'; + $zbp->Config('zxd_ctrlcenter') -> plugin_spider_spiders = 'Baiduspider,Baidu|Googlebot,Google|Sosospider,SoSo|YoudaoBot,YouDao|bingbot,Bing|Sogou web spider,SoGou|Yahoo! Slurp,Yahoo|Alexa,Alexa|360Spider,So'; + + $zbp->SaveConfig('zxd_ctrlcenter'); + } + + // 判断表格是否存在在,如果不存在就创建表 + zxd_ctrlcenter_spider_CreateTable(); + +} +function UninstallPlugin_zxd_ctrlcenter() { + // 微信打赏 + // global $zbp; + // $zbp->DelConfig('zxd_ctrlcenter'); + + // 蜘蛛来访 + // global $zbp; + // $zbp->DelConfig('SpiderStatistics'); +// zxd_ctrlcenter_spider_DelTable(); +} + + +// 顶部快捷方式 +function zxd_ctrlcenter_AddMenu(&$m){ + global $zbp; + $m[]=MakeTopMenu('root', '控制中心', $zbp->host . 'zb_users/plugin/zxd_ctrlcenter/main.php','','topmenu_zxd_ctrlcenter_spider'); +} + +// 蜘蛛来访 +function zxd_ctrlcenter_Index_End() { + global $zbp; + $array = array(); + $agent = null; + $status = null; + $url = 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; + $ip = GetGuestIP(); + $datetime = time(); + + $spiders = explode('|', $zbp->Config('zxd_ctrlcenter') -> plugin_spider_spiders); + + foreach ($spiders as $key => $spider) { + $spidername = explode(',', $spider); + if(strpos(GetGuestAgent(), $spidername[0]) !== false) { + $agent = $spidername[1]; + break; + } + } + + if($url && $agent) { + $array = array('Spider_Name' => $agent, 'Spider_IP' => $ip, 'Spider_DateTime' => $datetime, 'Spider_Url' => $url, 'Spider_Status' => 200); + + $sql = $zbp->db->sql->Insert($zbp->table['zxd_ctrlcenter_spider'], $array); + $zbp->db->Insert($sql); + } +} \ No newline at end of file diff --git a/logo.png b/logo.png new file mode 100644 index 0000000..16b046a Binary files /dev/null and b/logo.png differ diff --git a/main.php b/main.php new file mode 100644 index 0000000..7e9e9f4 --- /dev/null +++ b/main.php @@ -0,0 +1,187 @@ +Load(); +$action = 'root'; +if (!$zbp->CheckRights($action)) { $zbp->ShowError(6); die(); } +if (!$zbp->CheckPlugin('zxd_ctrlcenter')) { $zbp->ShowError(48); die(); } + +$blogtitle = '控制中心'; +require $blogpath . 'zb_system/admin/admin_header.php'; +require $blogpath . 'zb_system/admin/admin_top.php'; +/* 公共头部结束 */ + +// 当前用户打开的子插件 +if(!empty($_GET['plugin'])) + $PluginName = trim($_GET['plugin']); // trim函数去除获得参数的首尾空格 +else + $PluginName = ""; +if($PluginName=="home") $PluginName=""; // 如果请求的是首页,$PluginName设置为空 + +// 初始化全局变量 +require $blogpath.'zb_users/plugin/zxd_ctrlcenter/config.php'; + +// 为后续两次遍历定义变量 +$dir=$zbp->Config('zxd_ctrlcenter')->path.'plugin/'; // 遍历子插件所在Plugin目录 +$file_arr = scandir($dir); +?> + +
+
+ +
+ + + + + + Config('zxd_ctrlcenter')->path,$zbp->Config('zxd_ctrlcenter')->urlpath,$newpath); + include $newpath.'manage/config.php'; /*包含插件的名称$PluginTitle*/ + include $newpath.'manage/status.php'; // 检查插件是否启用,status.php + ?> + + + + + +
子插件名称操作
" style="width:32px; height:32px;"/> + 停用" + onclick="window.open().location = ''; "> +    + 管理
Config('zxd_ctrlcenter')->path.'about/readme.html'; // 插件介绍,readme.html + $copyrightfilepath = $zbp->Config('zxd_ctrlcenter')->relativepath; // 设置版权信息文件,plugin.xml + include $zbp->Config('zxd_ctrlcenter')->path.'public/copyright.php'; // 添加版权信息 + $PluginTitle = "关于"; + + } elseif ($PluginName == "DeleteConfig") /* 清除设置 */ {// style="hidden + // $PluginTitle = "清除所有设置"; + ?> +
+ +
var result = confirm('你真的想要清除本插件的全部设置吗?\\r\\n注意:插件设置一经清除,无法恢复!\\r\\n您确认要清除吗?'); document.writeln(result);"; + // echo ''; + // if($result2!="true") { goto QuitDeleteConfig; } + + //require $zbp->Config('zxd_ctrlcenter')->path.'public/Delete-ctrlcenter-Config.php'; // + + // + // if(!$result1) + // $result =""; + // if($result){ + + // } + + } else /* 插件页(或者插件不存在) */ { + require $zbp->Config('zxd_ctrlcenter')->path.'plugin/'.$PluginName.'/manage/status.php'; // 检查插件是否启用,status.php【如果插件不存在这里会报错】 + require $zbp->Config('zxd_ctrlcenter')->path.'plugin/'.$PluginName.'/manage/config.php'; // 插件config页,config.php(包含插件的名称$PluginTitle) + if($PluginIntro!="") // 如果插件有信息页面,则输出信息页面,否则不输出 + echo $PluginIntro."
"; // 插件config页,config.php中的$PluginIntro变量 + if($pluginstatus) /* 插件已启用 */ { + require $zbp->Config('zxd_ctrlcenter')->path.'public/plugin-disbtn.php'; // 添加禁用插件按钮 + echo "
"; + if(file_exists($zbp->Config('zxd_ctrlcenter')->path.'plugin/'.$PluginName.'/main.php')) // 如果插件有设置页面,则输出设置页面,否则不输出 + require $zbp->Config('zxd_ctrlcenter')->path.'plugin/'.$PluginName.'/main.php'; // 插件设置页,main.php + } else /* 插件未启用 */ { + require $zbp->Config('zxd_ctrlcenter')->path.'public/plugin-enbbtn.php'; // 添加启用插件按钮 + echo "
"; + } + $copyrightfilepath =$zbp->Config('zxd_ctrlcenter')->relativepath.'plugin/'.$PluginName.'/'; // 设置版权信息文件,plugin.xml + include $zbp->Config('zxd_ctrlcenter')->path.'public/copyright.php'; // 添加版权信息 + } + ?> +
+
+ + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin.xml b/plugin.xml new file mode 100644 index 0000000..1ff8290 --- /dev/null +++ b/plugin.xml @@ -0,0 +1,46 @@ + + +zxd_ctrlcenter +控制中心 + +【使用前务必仔细阅读说明!】集多种zblog网站小工具于一身,不断更新中... +集多种zblog网站小工具于一身,不断更新中... +欢迎大家前来提提建议或者意见,我会努力不断优化改进本插件的。 +使用前一定要备份网站,在测试站调试好后再部署到主要站点上,如果因为使用本插件导致网站数据丢失,作者不承担任何责任,谢谢理解! +main.php +include.php +1 + + 张小弟之家 + 2291200076@vip.qq.com + https://only4.work/ + + + + + + +162135 +1.1.1 +2020-07-06 +2020-08-20 +0 +5.4 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/404/include.php b/plugin/404/include.php new file mode 100644 index 0000000..20822cd --- /dev/null +++ b/plugin/404/include.php @@ -0,0 +1,25 @@ +Config('zxd_ctrlcenter')->plugin_404_Enable) + return false; + + if (!in_array("Status: 404 Not Found", headers_list())) { + return false; + } + + + $url = $zbp->Config('zxd_ctrlcenter')->plugin_404_redirect_url; + + $delay = $zbp->Config('zxd_ctrlcenter')->delay ?: 0; + if ($url && preg_match("/^http[s]?:\/\/.+\.\w+/", $url)){ + // 采用 js 跳转兼容性好 + if ($delay==0 && function_exists("RedirectByScript")) { + RedirectByScript($url); + }else{ + // 采用 html + echo ''; + die(); + } + } +} \ No newline at end of file diff --git a/plugin/404/logo.png b/plugin/404/logo.png new file mode 100644 index 0000000..e23e6c4 Binary files /dev/null and b/plugin/404/logo.png differ diff --git a/plugin/404/main.php b/plugin/404/main.php new file mode 100644 index 0000000..9337c04 --- /dev/null +++ b/plugin/404/main.php @@ -0,0 +1,68 @@ +ShowHint('bad', '自定义 Url 不正确'); + } else { + $zbp->Config('zxd_ctrlcenter')-> plugin_404_redirect_url = $redirect_url; + $zbp->SaveConfig('zxd_ctrlcenter'); + $zbp->ShowHint('good'); + } +} +?> + +
+ +
+
+
+ GetCSRFToken() . '">'; + } + ?> + + + + + + + + + + + +
+

+ 配置项 +

+
+

+ 设置 +

+
+

+ 说明 +

+
+

+ 重定向链接 +

+
+

+ +

+
+ 输入重定向的【完整】链接地址 +
+

+ +
+
+ +
+ \ No newline at end of file diff --git a/plugin/404/manage/config.php b/plugin/404/manage/config.php new file mode 100644 index 0000000..8d170a0 --- /dev/null +++ b/plugin/404/manage/config.php @@ -0,0 +1,3 @@ +window.close(); window.opener.location.reload(); '; +switch ($status_action) { + case 'chk': + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_404_Enable; + break; + case 'enb': + $zbp->Config('zxd_ctrlcenter')-> plugin_404_Enable = true; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + case 'dis': + $zbp->Config('zxd_ctrlcenter')-> plugin_404_Enable = false; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + + default: + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_404_Enable; + break; +} +?> + diff --git a/plugin/404/plugin.xml b/plugin/404/plugin.xml new file mode 100644 index 0000000..3706a42 --- /dev/null +++ b/plugin/404/plugin.xml @@ -0,0 +1,44 @@ + + +ThxPage404 +自定义404链接 + +自定义404链接 +当页面出现404时可以自定义跳转链接 +main.php +include.php +1 + + Thx + null@null.com + www.izy123.com + + + + + + +151935 +1.0 +2019-11-07 +2020-04-22 +0 +5.6 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/code/clipboard.min.js b/plugin/code/clipboard.min.js new file mode 100644 index 0000000..c9f467a --- /dev/null +++ b/plugin/code/clipboard.min.js @@ -0,0 +1 @@ +!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(window,function(){return function(t){var e={};function n(o){if(e[o])return e[o].exports;var r=e[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(o,r,function(e){return t[e]}.bind(null,r));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===o(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,c.default)(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new i.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return s("action",t)}},{key:"defaultTarget",value:function(t){var e=s("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return s("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach(function(t){n=n&&!!document.queryCommandSupported(t)}),n}}]),e}();function s(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}t.exports=l},function(t,e,n){"use strict";var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t=this,e="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[e?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,i.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,i.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var t=void 0;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":o(t))||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),t}();t.exports=a},function(t,e){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var o=window.getSelection(),r=document.createRange();r.selectNodeContents(t),o.removeAllRanges(),o.addRange(r),e=o.toString()}return e}},function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var o=this;function r(){o.off(t,r),e.apply(n,arguments)}return r._=e,this.on(t,r,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,r=n.length;o + + + +This is a custom SVG webfont generated by Font Squirrel. +Copyright : 199091 Apple Computer Inc 199091 Type Solutions Inc 199091 The Font Bureau Inc + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/code/font/monaco-webfont.ttf b/plugin/code/font/monaco-webfont.ttf new file mode 100644 index 0000000..376bdab Binary files /dev/null and b/plugin/code/font/monaco-webfont.ttf differ diff --git a/plugin/code/font/monaco-webfont.woff b/plugin/code/font/monaco-webfont.woff new file mode 100644 index 0000000..1d386f7 Binary files /dev/null and b/plugin/code/font/monaco-webfont.woff differ diff --git a/plugin/code/include.php b/plugin/code/include.php new file mode 100644 index 0000000..5f7706b --- /dev/null +++ b/plugin/code/include.php @@ -0,0 +1,5 @@ +footer .=''; +} diff --git a/plugin/code/logo.png b/plugin/code/logo.png new file mode 100644 index 0000000..400ebe1 Binary files /dev/null and b/plugin/code/logo.png differ diff --git a/plugin/code/manage/config.php b/plugin/code/manage/config.php new file mode 100644 index 0000000..cdbd588 --- /dev/null +++ b/plugin/code/manage/config.php @@ -0,0 +1,4 @@ +window.close(); window.opener.location.reload(); '; +switch ($status_action) { + case 'chk': + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_code_Enable; + break; + case 'enb': + $zbp->Config('zxd_ctrlcenter')-> plugin_code_Enable = true; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + case 'dis': + $zbp->Config('zxd_ctrlcenter')-> plugin_code_Enable = false; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + + default: + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_code_Enable; + break; +} +?> \ No newline at end of file diff --git a/plugin/code/plugin.xml b/plugin/code/plugin.xml new file mode 100644 index 0000000..ca5d620 --- /dev/null +++ b/plugin/code/plugin.xml @@ -0,0 +1,44 @@ + + +z_codeplus +野路子代码显示优化 Plus(张小弟之家修改,修正编辑代码区域太小的问题) +https://yeelz.com +修改UE编辑器默认的代码高亮效果,并加入复制、运行、编辑功能 +修改UE编辑器默认的代码高亮效果,并加入复制、运行、编辑功能,兼容自带UE编辑器和NE编辑器 + +include.php +1 + + 隔壁老李 + 393988832@qq.com + https://yeelz.com + + + + + + +151935 +1.1 +2019-12-06 +2020-04-15 +0 +5.2 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/code/svg/bianji.svg b/plugin/code/svg/bianji.svg new file mode 100644 index 0000000..e592e74 --- /dev/null +++ b/plugin/code/svg/bianji.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/plugin/code/svg/bianjigo.svg b/plugin/code/svg/bianjigo.svg new file mode 100644 index 0000000..1d42026 --- /dev/null +++ b/plugin/code/svg/bianjigo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/plugin/code/svg/copy.svg b/plugin/code/svg/copy.svg new file mode 100644 index 0000000..d439fd9 --- /dev/null +++ b/plugin/code/svg/copy.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/plugin/code/svg/yunxing.svg b/plugin/code/svg/yunxing.svg new file mode 100644 index 0000000..4a55ef3 --- /dev/null +++ b/plugin/code/svg/yunxing.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/plugin/code/z_codeplus.css b/plugin/code/z_codeplus.css new file mode 100644 index 0000000..991c27c --- /dev/null +++ b/plugin/code/z_codeplus.css @@ -0,0 +1,75 @@ +@charset "utf-8"; +/** + * 作品:Z-Blog代码高亮+复制 + * 作者:隔壁老李 + * 网址:https://zpanz.com + * 本插件完全免费,请勿删除此段内容 + */ +@font-face { + font-family: 'MonacoRegular'; + src: url(font/monaco-webfont.eot); + src: url(font/monaco-webfont.eot?#iefix) format('embedded-opentype'), url(font/monaco-webfont.woff) format('woff'), url(font/monaco-webfont.ttf) format('truetype'), url(font/monaco-webfont.svg#MonacoRegular) format('svg'); + font-weight: normal; + font-style: normal +} +code[class*="language-"], pre[class*="language-"] { + color:#fff; + text-shadow: none; + font-size: 1rem; + font-family:Monaco,'MonacoRegular','Microsoft Yahei',monospace; + } +pre[class*="language-"] { + border-radius: 0.3em; + margin: .5em 0 2em 0; +} + +:not(pre) > code[class*="language-"], pre[class*="language-"] { + background: #1f1f1f; +} +.prism-token.prism-punctuation { + color: #fff; +} +.prism-token.property, .prism-token.prism-tag, .prism-token.prism-boolean, .prism-token.prism-number, .prism-token.prism-constant, .prism-token.prism-symbol, .prism-token.prism-deleted { + color: #f92650; +} +.prism-token.prism-selector, .prism-token.prism-attr-name, .prism-token.prism-string, .prism-token.prism-char, .prism-token.prism-builtin, .prism-token.prism-inserted { + color: #a6e22d; +} +.prism-token.prism-operator, .prism-token.prism-entity, .prism-token.prism-url, .prism-language-css .prism-token.prism-string, .prism-style .prism-token.prism-string { + color: #fff; + background: none; +} +.prism-token.prism-atrule, .prism-token.prism-attr-value, .prism-token.prism-keyword { + color: #e6db5d; +} +.prism-token.prism-function { + color: #DD4A68; +} +.prism-line-numbers .prism-line-numbers-rows { + border-right: none; +} +.prism-line-numbers-rows > span:before { + color: #868686; + padding-right: none; + text-align: center; +} +div.prism-show-language > div.prism-show-language-label[data-language] { + background-color: #f4f5f9; + border: 1px solid #f4f5f9; + font-size: 0.8em; + border-radius: 0 0.3em 0; + padding: 0 0.5em; +} + +.prism-show-language-label img.z_go{ + display: inline; + margin: 0 8px 3px 0; +} +div.post-body code { + border: none; +} +.cdm_code{display:none;padding:10px;font-size: 1rem; + font-family:Monaco,'MonacoRegular','Microsoft Yahei',monospace;color: #404b69;background-color: #f4f5f9; margin: .5em 0 2em 0;} +.zcodehide{display:none;} +textarea.zcodeshow{display:block;width: 100%;} +.cdmtip{position:fixed;top:50%;left:50%;color:#f90;font-size:18px;font-family:'\5FAE\8F6F\96C5\9ED1';margin-top:-10px} diff --git a/plugin/code/z_codeplus.js b/plugin/code/z_codeplus.js new file mode 100644 index 0000000..a81047b --- /dev/null +++ b/plugin/code/z_codeplus.js @@ -0,0 +1,100 @@ +var preNum = 0; +var preStyle = 'pre[class*="brush:"],pre[class*="prism"],pre>code'; +var copyimg = bloghost + "zb_users/plugin/zxd_ctrlcenter/plugin/code/svg/copy.svg"; +var goimg = bloghost + "zb_users/plugin/zxd_ctrlcenter/plugin/code/svg/yunxing.svg"; +var bjimg = bloghost + "zb_users/plugin/zxd_ctrlcenter/plugin/code/svg/bianji.svg"; +var bjgoimg = bloghost + "zb_users/plugin/zxd_ctrlcenter/plugin/code/svg/bianjigo.svg"; +$(preStyle).each(function() { + yid = "pre_" + preNum; + precode = $(this).html(); + xyattr = $(this).attr("class"); + if ($("pre>code").length) { + $cdom = $(this).parent() + } else { + $cdom = $(this) + } + $cdom.attr("id", yid); + $cdom.after('"); + preNum++ +}); +$(document).ready(function() { + var a = 0; + $("pre").each(function() { + var d = "pre_" + a; + var c = $(this).prev(); + var b = ''; + if (c.hasClass("prism-show-language")) { + c.find("div").prepend(b) + } else { + $(this).before( + '
' + b + + "
") + } + a++ + }) +}); +$('textarea[id*="tpre"]').blur(function() { + $(this).text($(this).val()) +}); + +function runCode(a) { + var b = window.open("", "", ""); + b.document.open("text/html", "replace"); + b.opener = null; + b.document.write($("#" + a).next("textarea").html().replace(/</g, "<").replace(/>/g, ">").replace(/ /g, " ") + .replace(/"/g, '"').replace(/&/g, "&")); + b.document.close() +} +document.writeln(''; +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; +} +?> \ No newline at end of file diff --git a/plugin/grey/plugin.xml b/plugin/grey/plugin.xml new file mode 100644 index 0000000..352339b --- /dev/null +++ b/plugin/grey/plugin.xml @@ -0,0 +1,38 @@ + + +xd_gray +整站变灰 + +整站变灰 +整站变灰 + +include.php +1 + + xiandan + + + + + + + + +151626 +1.0 +2017-02-01 +2017-02-05 +0 + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/spider/include.php b/plugin/spider/include.php new file mode 100644 index 0000000..423669d --- /dev/null +++ b/plugin/spider/include.php @@ -0,0 +1,53 @@ +array('Spider_ID','integer','',0), + 'Name'=>array('Spider_Name','string',20,''), + 'IP'=>array('Spider_IP','string',15,''), + 'DateTime'=>array('Spider_DateTime','integer','',0), + 'Url'=>array('Spider_Url','string',250,''), + 'Status'=>array('Spider_Status','integer','',1), +); + +function zxd_ctrlcenter_spider_SubMenu($id){ + $arySubMenu = array( + 0 => array('基本设置', 'config', 'left', false), + 1 => array('查看记录', 'spider', 'left', false), + + ); + foreach($arySubMenu as $k => $v){ + echo ''.$v[0].''; + } +} + +class zxd_ctrlcenter_spider extends Base{ + + function __construct() { + global $zbp; + parent::__construct($zbp->table['zxd_ctrlcenter_spider'], $zbp->datainfo['zxd_ctrlcenter_spider']); + + $this->DateTime = time(); + } + + public function Time($s='Y-m-d H:i:s'){ + return date($s,(int)$this->DateTime); + } +} + + +function zxd_ctrlcenter_spider_CreateTable() { + global $zbp; + if ($zbp->db->ExistTable($GLOBALS['table']['zxd_ctrlcenter_spider']) == false) { + $s = $zbp->db->sql->CreateTable($GLOBALS['table']['zxd_ctrlcenter_spider'], $GLOBALS['datainfo']['zxd_ctrlcenter_spider']); + $zbp->db->QueryMulit($s); + } +} + +function zxd_ctrlcenter_spider_DelTable() { + global $zbp; + if ($zbp->db->ExistTable($zbp->table['zxd_ctrlcenter_spider']) == true) { + $s = $zbp->db->sql->DelTable($zbp->table['zxd_ctrlcenter_spider']); + $zbp->db->QueryMulit($s); + } +} \ No newline at end of file diff --git a/plugin/spider/logo.png b/plugin/spider/logo.png new file mode 100644 index 0000000..57ff656 Binary files /dev/null and b/plugin/spider/logo.png differ diff --git a/plugin/spider/main.php b/plugin/spider/main.php new file mode 100644 index 0000000..0f4a010 --- /dev/null +++ b/plugin/spider/main.php @@ -0,0 +1,111 @@ +Load(); +$action='root'; + +$act = ''; +if (isset($_GET['act']) && $_GET['act']){$act = $_GET['act'] == "" ? 'config' : $_GET['act'];} +else $act = "config"; +?> + + + + + + +Config('zxd_ctrlcenter') -> plugin_spider_viewconut = $_POST['viewconut']; + $zbp->Config('zxd_ctrlcenter') -> plugin_spider_spiders = $_POST['spiders']; + $zbp->SaveConfig('zxd_ctrlcenter'); + $zbp->SetHint('good'); + Redirect('./main.php?&plugin=spider&act=config'); + } +?> +

如果下面两个文本框默认状态下是空白的,没有内容,说明插件升级不完全,将【控制中心】插件关闭后再开启一次即可。关闭插件不会丢失其他子插件配置。

+
+ + + + + + + + + + + + + +
显示篇数:
蜘蛛列表:
格式:蜘蛛名称,显示名称。
多个用“|”分隔,如:Baiduspider,Baidu|Googlebot,Google。
 
+ + GetCSRFToken() . '">';}?> +
+

模拟百度抓取查看插件效果:点击前往
输入要检测的网页URL,如您的Z-Blog网站首页:

+
+【备注】 +

1. 本插件可与【流年岁月】的【来访蜘蛛统计】同时开启,但无必要,且数据不互通,建议只开启一个。同时开启相当于每个插件分别记录,互不干扰。

+ +

2. 右上角清除设置和关闭插件均不会清空统计结果,如需删除或清空统计结果,请登录后台数据库删除表【表前缀_zxd_ctrlcenter_spider】。再次使用本【蜘蛛来访统计】子插件,需要关闭【控制中心】插件然后再次打开以创建新表。

+ +

3. 本插件与爱站网无任何利益关系,提供上方的跳转将连接仅为方便测试插件是否能正常工作。对于该站点,本插件作者不保证服务始终可用,也不承担因此引发的任何问题。

+ +
+【默认设置】 +

如果您不小心修改了上方文本框中的内容,可以将下方参数复制到上方文本框并保存以恢复默认设置。

+ +

显示篇数:20

+ +

蜘蛛列表:Baiduspider,Baidu|Googlebot,Google|Sosospider,SoSo|YoudaoBot,YouDao|bingbot,Bing|Sogou web spider,SoGou|Yahoo! Slurp,Yahoo|Alexa,Alexa|360Spider,So

+
+ +'; + echo ' + ID + 蜘蛛名称 + 蜘蛛IP + 抓取时间 + 抓取地址 + 抓取状态 + '; + + $p = new Pagebar('{%host%}zb_users/plugin/zxd_ctrlcenter/main.php?plugin=spider&act=spider{&page=%page%}',false); + $p->PageCount = $zbp->Config('zxd_ctrlcenter') -> plugin_spider_viewconut; + $p->PageNow = (int)GetVars('page','GET')==0?1:(int)GetVars('page','GET'); + $p->PageBarCount = $zbp->pagebarcount; + + $select = array('*'); + $where = array(); + $order = array('Spider_ID'=>'DESC'); + $limit = array(($p->PageNow-1) * $p->PageCount,$p->PageCount); + $option = array('pagebar'=>$p); + + error_reporting(0); // 屏蔽掉可能出现的 Undefined index: ZC_MYSQL_ENGINE 提示 + $sql = $zbp->db->sql->Select($zbp->table['zxd_ctrlcenter_spider'], $select, $where, $order, $limit, $option); + $array = $zbp->GetListType('zxd_ctrlcenter_spider',$sql); + + + foreach ($array as $key => $value) { + echo ''; + echo '' . $value->ID . ''; + echo '' . $value->Name . ''; + echo '' . $value->IP . ''; + echo '' .$value->Time() . ''; + echo '' .$value->Url . ''; + echo '' . $value->Status . ''; + echo ''; + } + + echo ''; + echo '

'; + + foreach ($p->buttons as $key => $value) { + echo '' . $key . '  ' ; + } + + echo '

'; + +} ?> \ No newline at end of file diff --git a/plugin/spider/manage/config.php b/plugin/spider/manage/config.php new file mode 100644 index 0000000..0716337 --- /dev/null +++ b/plugin/spider/manage/config.php @@ -0,0 +1,3 @@ +window.close(); window.opener.location.reload(); '; +switch ($status_action) { + case 'chk': + $pluginstatus = $zbp->Config('zxd_ctrlcenter') -> plugin_spider_Enable; + break; + case 'enb': + $zbp->Config('zxd_ctrlcenter') -> plugin_spider_Enable = true; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + case 'dis': + $zbp->Config('zxd_ctrlcenter') -> plugin_spider_Enable = false; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + + default: + $pluginstatus = $zbp->Config('zxd_ctrlcenter') -> plugin_spider_Enable; + break; +} +?> + diff --git a/plugin/spider/plugin.xml b/plugin/spider/plugin.xml new file mode 100644 index 0000000..5235dd0 --- /dev/null +++ b/plugin/spider/plugin.xml @@ -0,0 +1,38 @@ + + +SpiderStatistics +来访蜘蛛统计(张小弟之家修改;修复开发模式下部分站点报Notice错误的Bug,并添加CSRF保护,使用更安全) +http://www.fengwensheng.com +来访蜘蛛统计,统计来访蜘蛛 +来访蜘蛛统计,统计来访蜘蛛 +main.php?act=config +include.php +1 + + 流年岁月 + 372664700@qq.com + http://www.fengwensheng.com/ + + + + + + +140614 +1.3 +2014-08-26 +2015-03-17 +0 + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/spider/style.css b/plugin/spider/style.css new file mode 100644 index 0000000..a06129c --- /dev/null +++ b/plugin/spider/style.css @@ -0,0 +1,70 @@ +/** + * @Description: 在线QQ悬浮插件 + * @Author: Liuzp + * @Author URL: http://www.liuzp.com + */ + +.com-hd{ + margin: 20px 0 15px; +} + +.com-hd b{ + font-size:16px; + color:#333; + font-family:'Microsoft Yahei'; +} + +.tb-set{ + border-collapse: collapse; +} + +.tb-set tr td{ + padding: 10px 5px; + border: 1px solid #e0e0e0; +} + +.tb-set tr td input, .tb-set tr td img{ + margin:0 auto; + vertical-align: middle; +} + +.tb-set tr td b{ + color: #666; +} + +.tb-set tr td .sel{ + height:17px; + border:1px solid #ccc; + border-radius:5px; + outline: none; + color:#333; + padding:3px 1px; +} + +.tb-set tr td .sel select{ + border:none; + outline:none; + width:120px; +} + +.tb-set tr td .txt{ + width:240px; + height:18px; + border:1px solid #ccc; + line-height:23px; + border-radius:5px; + outline: none; + color:#333; + padding:3px 0 2px 5px; +} + +.tb-set tr td .txt-lar{ + width:450px; + height:100px; + border:1px solid #ccc; + line-height:15px; +} + +.tb-set tr td .txt-sho{ + width:150px; +} \ No newline at end of file diff --git a/plugin/wxreward/include.php b/plugin/wxreward/include.php new file mode 100644 index 0000000..988b83f --- /dev/null +++ b/plugin/wxreward/include.php @@ -0,0 +1,31 @@ +footer .= ' '; +} +function zxd_ctrlcenter_wxreward_html(&$template){ + global $zbp; + if ($zbp->Config('zxd_ctrlcenter')->plugin_wxreward_picurl){ + $QR=$zbp->Config('zxd_ctrlcenter')->plugin_wxreward_picurl; + }else{ + $QR= $zbp->host.'zb_users/plugin/zxd_ctrlcenter/plugin/wxreward/src/wxpay.jpg'; + } + if ($zbp->Config('zxd_ctrlcenter')->plugin_wxreward_txt){ + $txt=$zbp->Config('zxd_ctrlcenter')->plugin_wxreward_txt; + }else{ + $txt='微信扫一扫,打赏作者吧~'; + } + $html='
打赏
'; + $content=$template->GetTags('article')->Content; + $template->GetTags('article')->Content=$content . $html; + +} \ No newline at end of file diff --git a/plugin/wxreward/logo.png b/plugin/wxreward/logo.png new file mode 100644 index 0000000..4928213 Binary files /dev/null and b/plugin/wxreward/logo.png differ diff --git a/plugin/wxreward/main.php b/plugin/wxreward/main.php new file mode 100644 index 0000000..2dc68b7 --- /dev/null +++ b/plugin/wxreward/main.php @@ -0,0 +1,73 @@ +Config('zxd_ctrlcenter')->plugin_wxreward_picurl){ + $picurl=$zbp->Config('zxd_ctrlcenter')->plugin_wxreward_picurl; +}else{ + $picurl=$zbp->Config('zxd_ctrlcenter')->urlpath.'plugin/wxreward/src/wxpay.jpg'; +}//名称 + +if ($zbp->Config('zxd_ctrlcenter')->plugin_wxreward_txt){ + $txt=$zbp->Config('zxd_ctrlcenter')->plugin_wxreward_txt; +}else{ + $txt='微信扫一扫,打赏作者吧~'; +} + +if(isset($_POST['submit'])){ + /*SEO*/ + $zbp->Config('zxd_ctrlcenter')->plugin_wxreward_picurl = $_POST['picurl']; + $zbp->Config('zxd_ctrlcenter')->plugin_wxreward_txt = $_POST['txt']; + $zbp->SaveConfig('zxd_ctrlcenter'); + $zbp->ShowHint('good'); +} +?> + + +
+
+ 微信支付二维码设置: +
+ GetCSRFToken() . '">'; + } + ?> + 方式1.本站上传:(选择图片后,请点击上传按钮)
+ +
+ +
+ + GetCSRFToken() . '">';}?> + + 方式2.已知微信支付二维码URL:
+ +
+ 底部文字设置: +
+
+
+
+

当前二维码

+

微信打赏二维码

+
+
+
+
+ + + +


+一些注意事项: +

微信生成的二维码图片建议先裁剪再上传

+

上传的图片大小不要太大,不然上传与网页加载时间会延长,不利于网页展示。

+

该插件修改自“阿木林”作者的“wxreward”插件(应用商店id为1264),本子插件不得与“wxreward”插件同时开启!!!

+

图片上传目录:[你的网站Z-Blog地址/zb_users/plugin/zxd_ctrlcenter/plugin/wxreward/src/]。如需删除上传图片,请在登录后台ftp,删除相应图片

+

+通过手机微信获取付款二维码,操作步骤如下: +

+ 1.打开微信,点击右上角“+”号,点击“收钱”,进入微信收钱页面;
+ 2.长按二维码,点击“保存图片”,保存图片到手机;
+ 3.将图片上传到电脑;
+ 4.将二维码图片传到上方;或者上传到第三方图床并复制URL在上方保存。 +

\ No newline at end of file diff --git a/plugin/wxreward/manage/config.php b/plugin/wxreward/manage/config.php new file mode 100644 index 0000000..97d596a --- /dev/null +++ b/plugin/wxreward/manage/config.php @@ -0,0 +1,3 @@ +window.close(); window.opener.location.reload(); '; +switch ($status_action) { + case 'chk': + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_wxreward_Enable; + break; + case 'enb': + $zbp->Config('zxd_ctrlcenter')-> plugin_wxreward_Enable = true; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + case 'dis': + $zbp->Config('zxd_ctrlcenter')-> plugin_wxreward_Enable = false; + $zbp->SaveConfig('zxd_ctrlcenter'); + echo $Close; + break; + + default: + $pluginstatus = $zbp->Config('zxd_ctrlcenter')-> plugin_wxreward_Enable; + break; +} +?> \ No newline at end of file diff --git a/plugin/wxreward/plugin.xml b/plugin/wxreward/plugin.xml new file mode 100644 index 0000000..1040d81 --- /dev/null +++ b/plugin/wxreward/plugin.xml @@ -0,0 +1,40 @@ + + +wxreward +微信打赏(张小弟之家修改;并添加CSRF保护,使用更安全) + +无需更改模板代码,在文章末尾添加微信打赏功能,如果读者觉得这篇文章对他有用,可以用微信扫一扫打赏赞助。 +无需更改模板代码,在文章末尾添加微信打赏功能,如果读者觉得这篇文章对他有用,可以用微信扫一扫打赏赞助。 +main.php +include.php +1 + + 阿木林 + + + + + + + + +150101 +1.8 +2017-02-20 +2019-01-11 +0 +5.2 + + + + + + + + + + + + + + \ No newline at end of file diff --git a/plugin/wxreward/save.php b/plugin/wxreward/save.php new file mode 100644 index 0000000..1793c27 --- /dev/null +++ b/plugin/wxreward/save.php @@ -0,0 +1,27 @@ +Load(); +$action='root'; +if (!$zbp->CheckRights($action)) {$zbp->ShowError(6);die();} +if (!$zbp->CheckPlugin('zxd_ctrlcenter')) {$zbp->ShowError(48);die();} + +if($_GET['type'] == 'picurl' ){ + global $zbp; + foreach ($_FILES as $key => $value) { + if(!strpos($key, "_php")){ + if (is_uploaded_file($_FILES[$key]['tmp_name'])) { + $tmp_name = $_FILES[$key]['tmp_name']; + $name = $_FILES[$key]['name']; + @move_uploaded_file($_FILES[$key]['tmp_name'], $zbp->usersdir . 'plugin/zxd_ctrlcenter/plugin/wxreward/src/'. $name); + $zbp->Config('zxd_ctrlcenter')->plugin_wxreward_picurl = $zbp->host . 'zb_users/plugin/zxd_ctrlcenter/plugin/wxreward/src/'. $name; + $zbp->SaveConfig('zxd_ctrlcenter'); + } + } + } + + $zbp->SetHint('good','二维码上传成功'); + Redirect($zbp->Config('zxd_ctrlcenter')->urlpath . 'main.php?plugin=wxreward'); +} +?> \ No newline at end of file diff --git a/plugin/wxreward/src/ico-wechat.jpg b/plugin/wxreward/src/ico-wechat.jpg new file mode 100644 index 0000000..ce8f199 Binary files /dev/null and b/plugin/wxreward/src/ico-wechat.jpg differ diff --git a/plugin/wxreward/src/wx-reward.2.css b/plugin/wxreward/src/wx-reward.2.css new file mode 100644 index 0000000..da65070 --- /dev/null +++ b/plugin/wxreward/src/wx-reward.2.css @@ -0,0 +1,60 @@ +.gave { + height: 110px; + position: relative; + text-align: center; +} + +.gave .code::after { + border-color: #fff transparent transparent; + border-style: solid; + border-width: 10px; + content: ""; + height: 0; + left: 50%; + margin-left: -7.5px; + position: absolute; + top: 100%; + width: 0; +} +.gave .code { + background: #fff none repeat scroll 0 0; + border-radius: 5px; + bottom: 100%; + box-shadow: 0 0 15px #e5e5e5; + color: #68b3de; + display: none; + font-size: 13px; + height: 160px; + left: 50%; + box-sizing: content-box; + margin-left: -110px; + padding: 20px; + position: absolute; + width: 180px; + z-index: 999; + text-align: center; +} +#gave { + background: #f06363 none repeat scroll 0 0; + border-radius: 50%; + color: #fff !important; + display: inline-block; + font-size: 18px; + height: 75px; + line-height: 75px; + text-align: center; + width: 75px; + text-decoration: none; + } +#wechatCode img{ /* 严格限制QR图片 */ + height: 124px; + width: 124px; + border: medium none; + max-width: 100%; +} +#ico-wechat img{/* 严格限制wx图片 */ + height: 15px; + width: 20px; + border: medium none; + max-width: 100%; +} diff --git a/plugin/wxreward/src/wx-reward.css b/plugin/wxreward/src/wx-reward.css new file mode 100644 index 0000000..b9fc110 --- /dev/null +++ b/plugin/wxreward/src/wx-reward.css @@ -0,0 +1,55 @@ +.gave { + height: 110px; + position: relative; + text-align: center; +} + +.gave .code::after { + border-color: #fff transparent transparent; + border-style: solid; + border-width: 10px; + content: ""; + height: 0; + left: 50%; + margin-left: -7.5px; + position: absolute; + top: 100%; + width: 0; +} +.gave .code { + background: #fff none repeat scroll 0 0; + border-radius: 5px; + bottom: 100%; + box-shadow: 0 0 15px #e5e5e5; + color: #68b3de; + display: none; + font-size: 13px; + height: 160px; + left: 50%; + box-sizing: content-box; + margin-left: -110px; + padding: 20px; + position: absolute; + width: 180px; + z-index: 999; + text-align: center; +} +.gave a { + background: #f06363 none repeat scroll 0 0; + border-radius: 50%; + color: #fff !important; + display: inline-block; + font-size: 18px; + height: 75px; + line-height: 75px; + text-align: center; + width: 75px; + text-decoration: none; +} + +.gave .code > img { + height: 124px; + width: 124px; + border: medium none; + max-width: 100%; +} \ No newline at end of file diff --git a/plugin/wxreward/src/wx-reward.js b/plugin/wxreward/src/wx-reward.js new file mode 100644 index 0000000..6b57733 --- /dev/null +++ b/plugin/wxreward/src/wx-reward.js @@ -0,0 +1,13 @@ +jQuery(function ($) { + $("#gave").mouseover(function(){ + $("#wechatCode").css('display','block'); + }).mouseout(function(){ + $("#wechatCode").css('display','none'); + }) + + $("#wechatCode").mouseover(function(){ + $("#wechatCode").css('display','block'); + }).mouseout(function(){ + $("#wechatCode").css('display','none'); + }) +}) \ No newline at end of file diff --git a/plugin/wxreward/src/wxpay.jpg b/plugin/wxreward/src/wxpay.jpg new file mode 100644 index 0000000..fb9f341 Binary files /dev/null and b/plugin/wxreward/src/wxpay.jpg differ diff --git a/public/copyright.php b/public/copyright.php new file mode 100644 index 0000000..8dc684e --- /dev/null +++ b/public/copyright.php @@ -0,0 +1,103 @@ +"; +// var_dump($xml_arr); + +// function getattr1($attribute) { +// global $xml_arr; +// try { +// echo $xml_arr[$attribute]; +// } catch(Exception $e) { +// echo ""; +// } +// } + +?> +
+ + + + + +


\ No newline at end of file diff --git a/public/ctrlcenter_config.php b/public/ctrlcenter_config.php new file mode 100644 index 0000000..92c26ce --- /dev/null +++ b/public/ctrlcenter_config.php @@ -0,0 +1,24 @@ +Load(); +$action = 'root'; +if (!$zbp->CheckRights($action) || empty($_GET['action'])) { $zbp->ShowError(6); die(); } +if (!$zbp->CheckPlugin('zxd_ctrlcenter')) { $zbp->ShowError(48); die(); } + + //?>DelConfig('zxd_ctrlcenter'); ?> + + + + + function disbtnclick() { + window.open().location = ""; + } + + 插件已启用, + diff --git a/public/plugin-enbbtn.php b/public/plugin-enbbtn.php new file mode 100644 index 0000000..32a4f52 --- /dev/null +++ b/public/plugin-enbbtn.php @@ -0,0 +1,6 @@ + + 插件已禁用, \ No newline at end of file