Compare commits

...

2 Commits

Author SHA1 Message Date
MI15\Win 87566c39f3 v2.0.14-20230420 2023-04-20 21:03:34 +08:00
MI15\Win 5cae5af159 v2.0.13-20230418 2023-04-18 13:17:09 +08:00
18 changed files with 142 additions and 81 deletions
+23
View File
@@ -0,0 +1,23 @@
<?php if(!defined('DIR')){header('HTTP/1.1 404 Not Found');header("status: 404 Not Found");exit;}
//弥补主题配置目录名相同造成的窜数据的bug
//复制主题配置,并重新标记t类型
// 'theme_home','theme_login','theme_transit','theme_register';
$datas = select_db('user_config','*',['t'=>'theme']);
foreach ($datas as $data) {
$name = $data['k'];
unset($data['id']);
if($name == 'default'){
$data['t'] = 'theme_transit';
insert_db('user_config',$data);
}
if($name == 'WebStack-Hugo'){
$data['t'] = 'theme_transit';
insert_db('user_config',$data);
}
$data['t'] = 'theme_home';
insert_db('user_config',$data);
}
insert_db('updatadb_logs',['file_name'=>$file_name,'update_time'=>time(),'status'=>'TRUE','extra'=>'']);
delete_db('user_config',['t'=>'theme']);
+2 -1
View File
@@ -42,7 +42,8 @@ CREATE TABLE IF NOT EXISTS `updatadb_logs` (
UNIQUE KEY `file_name` (`file_name`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4;
INSERT INTO "updatadb_logs" ("id", "file_name", "update_time", "status", "extra") VALUES ('1', '20230417.php', '1681719049', 'TRUE', '');
INSERT INTO "updatadb_logs" ("file_name", "update_time", "status", "extra") VALUES ('20230417.php', '1681719049', 'TRUE', '');
INSERT INTO "updatadb_logs" ("file_name", "update_time", "status", "extra") VALUES ('20230420.php', '1681977368', 'TRUE', '');
-- 创建用户表
DROP TABLE IF EXISTS `global_user`;
+23
View File
@@ -0,0 +1,23 @@
<?php if(!defined('DIR')){header('HTTP/1.1 404 Not Found');header("status: 404 Not Found");exit;}
//弥补主题配置目录名相同造成的窜数据的bug
//复制主题配置,并重新标记t类型
// 'theme_home','theme_login','theme_transit','theme_register';
$datas = select_db('user_config','*',['t'=>'theme']);
foreach ($datas as $data) {
$name = $data['k'];
unset($data['id']);
if($name == 'default'){
$data['t'] = 'theme_transit';
insert_db('user_config',$data);
}
if($name == 'WebStack-Hugo'){
$data['t'] = 'theme_transit';
insert_db('user_config',$data);
}
$data['t'] = 'theme_home';
insert_db('user_config',$data);
}
insert_db('updatadb_logs',['file_name'=>$file_name,'update_time'=>time(),'status'=>'TRUE','extra'=>'']);
delete_db('user_config',['t'=>'theme']);
+2 -1
View File
@@ -35,7 +35,8 @@ CREATE TABLE IF NOT EXISTS "updatadb_logs" (
"extra" TEXT(512) NOT NULL DEFAULT "",
CONSTRAINT "file_name" UNIQUE ("file_name" ASC)
);
INSERT INTO "updatadb_logs" ("id", "file_name", "update_time", "status", "extra") VALUES ('1', '20230417.php', '1681719049', 'TRUE', '');
INSERT INTO "updatadb_logs" ("file_name", "update_time", "status", "extra") VALUES ('20230417.php', '1681719049', 'TRUE', '');
INSERT INTO "updatadb_logs" ("file_name", "update_time", "status", "extra") VALUES ('20230420.php', '1681977368', 'TRUE', '');
-- 创建用户表
CREATE TABLE IF NOT EXISTS "global_user" (
+4 -31
View File
@@ -53,32 +53,8 @@ if ($page == 'home') {
array_push($day_data[0]['data'],get_db('user_count','v',['uid'=>UID,'k'=>$date,'t'=>'index_Ymd'])??0);
array_push($day_data[1]['data'],get_db('user_count','v',['uid'=>UID,'k'=>$date,'t'=>'click_Ymd'])??0);
}
//var_dump(json_encode($day),$day_data);
}
//调试
if( $page == 'test' ) {
$dirs = get_dir_list(DIR.'/templates/home');
//var_dump($dirs);
foreach ($dirs as $dir) {
$path = DIR.'/templates/home/'.$dir; //目录完整路径
//没有信息文件则跳过
if(!is_file($path.'/info.json') ) {continue;}
//读取主题信息
$themes[$dir]['info'] = json_decode(@file_get_contents($path.'/info.json'),true);
//是否支持配置
$themes[$dir]['info']['config'] = is_file($path.'/config.php') ? '1':'0';
//预览图优先顺序:png>jpg>info>default
if(is_file($dirs.'/screenshot.png')){
$themes[$dir]['info']['screenshot'] = "./templates/home/".$dir."/screenshot.png";
}elseif(is_file($dirs.'/screenshot.jpg')){
$themes[$dir]['info']['screenshot'] = "./templates/home/".$dir."/screenshot.jpg";
}elseif(empty($themes[$dir]['info']['screenshot'])){
$themes[$dir]['info']['screenshot'] = "./templates/admin/static/42ed3ef2c4a50f6d.png";
}
//var_dump($themes);
}
}
//载入主题配置
if($page == 'config_home'){
$theme = $_GET['theme'];
@@ -92,7 +68,10 @@ if($page == 'config_home'){
$theme_config = empty($theme_config['config']) ? []:$theme_config['config'];
//读取用户主题配置
$theme_config_db = get_db('user_config','v',['t'=>'theme','k'=>$theme,'uid'=>UID]);
if(!in_array($_GET['fn'],['home','login','register','transit'])){
msg(-1,"参数错误");
}
$theme_config_db = get_db('user_config','v',['t'=>'theme_'.$_GET['fn'],'k'=>$theme,'uid'=>UID]);
$theme_config_db = unserialize($theme_config_db);
//如果不为空则合并数据
@@ -103,7 +82,6 @@ if($page == 'config_home'){
if(empty($theme_config)){
exit("<h3>获取主题配置失败</h3>");
}
//var_dump($theme_config);
require $config_path;
exit;
}
@@ -129,7 +107,6 @@ if( $page == 'theme_home' || $page == 'theme_login' || $page == 'theme_transit'
}elseif(empty($themes[$dir]['info']['screenshot'])){
$themes[$dir]['info']['screenshot'] = "./templates/admin/static/42ed3ef2c4a50f6d.png";
}
//var_dump($themes);
}
//获取当前主题
@@ -191,7 +168,6 @@ if( $page == 'theme_home' || $page == 'theme_login' || $page == 'theme_transit'
define('referrer',$data['referrer']);
}
}
//var_dump($themes);exit;
}
@@ -230,7 +206,6 @@ if ($page == 'menu') {
array_push($menu,$extend);
}
//如果是管理员则追加菜单
if($USER_DB['UserGroup'] == 'root'){
array_push($menu,
@@ -251,7 +226,6 @@ if ($page == 'menu') {
exit(json_encode($init));
}
//不带参数是载入框架
if(empty($page)){
$site = unserialize(get_db('user_config','v',['uid'=>UID,'k'=>'s_site']));
@@ -271,7 +245,6 @@ if(!empty($page)){
}
}
//加载静态库
function load_static($type){
if($type == 'css'){
+13 -1
View File
@@ -1231,10 +1231,22 @@ function write_theme(){
if(empty($_POST)){
msg(-1,"POST请求数据不能为空!");
}
write_user_config($_GET['t'],$_POST,'theme','主题配置');
//20230420,修复同名窜数据的问题!由于保存主题不提交模板类型,只能从来路中提取
parse_str(parse_url($_SERVER['HTTP_REFERER'])['query'],$GET);
if(empty($GET['fn']) && empty($_GET['template_type']) ){
msg(-1,"获取模板类型错误");
}
$fn = empty($GET['fn']) ? $_GET['template_type'] : $GET['fn'];
if(!in_array($fn,['home','login','register','transit'])){
msg(-1,"参数错误");
}
//0420 END
write_user_config($_GET['t'],$_POST,'theme_' . $fn,'主题配置');
msg(1,"保存成功!");
}
}
//读登录信息
function read_login_info(){
$page = empty(intval($_REQUEST['page'])) ? 1 : intval($_REQUEST['page']);
+7 -4
View File
@@ -42,9 +42,9 @@ function other_upsys(){
if($_POST['i'] == 2){
if(!is_subscribe('bool')){
msg(-1,'未检测到有效授权,
<a href="https://gitee.com/tznb/OneNav/wikis/%E8%AE%A2%E9%98%85%E6%9C%8D%E5%8A%A1%E6%8C%87%E5%BC%95" target="_blank" style="color: #01AAED;">购买授权</a>
<a href="https://gitee.com/tznb/TwoNav/wikis/pages?sort_id=7968669&doc_id=3767990" target="_blank" style="color: #01AAED;">购买授权</a>
<a href="https://gitee.com/tznb/TwoNav/releases" target="_blank" style="color: #01AAED;">手动更新</a>');
<a href="https://gitee.com/tznb/TwoNav/wikis/pages?sort_id=8013447&doc_id=3767990" target="_blank" style="color: #01AAED;">手动更新</a>');
}
//设置执行最长时间,0为无限制。单位秒!
set_time_limit(5*60);
@@ -499,6 +499,7 @@ function write_sys_settings(){
'Debug'=>['int'=>true,'min'=>0,'max'=>1,'msg'=>'调试模式参数错误'],
'Maintenance'=>['int'=>true,'min'=>0,'max'=>1,'msg'=>'维护模式参数错误'],
'Sub_domain'=>['int'=>true,'min'=>0,'max'=>1,'msg'=>'二级域名参数错误'],
'Privacy'=>['int'=>true,'min'=>0,'max'=>1,'msg'=>'强制私有参数错误'],
'copyright'=>['empty'=>true],
'global_header'=>['empty'=>true],
'global_footer'=>['empty'=>true],
@@ -519,11 +520,13 @@ function write_sys_settings(){
}
if(!is_subscribe('bool')){
if($_POST['Sub_domain'] == 1){$o_config['Sub_domain'] = 0;$filter = true;}
if($_POST['Privacy'] == 1){$o_config['Privacy'] = 0;$filter = true;}
if(!empty($_POST['copyright'])){$o_config['copyright'] = "";$filter = true;}
if(!empty($_POST['global_header'])){$o_config['global_header'] = "";$filter = true;}
if(!empty($_POST['global_footer'])){$o_config['global_footer'] = "";$filter = true;}
if(!empty($_POST['apply'])){$o_config['apply'] = 0;$filter = true;}
if(!empty($_POST['guestbook'])){$o_config['guestbook'] = 0;$filter = true;}
if($_POST['apply'] == 1){$o_config['apply'] = 0;$filter = true;}
if($_POST['guestbook'] == 1){$o_config['guestbook'] = 0;$filter = true;}
if($_POST['link_extend'] == 1){$o_config['link_extend'] = 0;$filter = true;}
}
update_db("global_config", ["v" => $o_config], ["k" => "o_config"],[1,($filter ?"保存成功,未检测到有效授权,带*号的配置无法为你保存":"保存成功")]);
+15 -23
View File
@@ -8,17 +8,20 @@ if(empty($id)){Not_Found();}
//查询链接信息
$where['lid'] = $id;
$where['uid'] = UID;
//$where['status'] = 1;
$where['status'] = 1;
$link = get_db('user_links','*',$where);
//查找失败时显示404
if(empty($link)){
Not_Found();
}
if(empty($link)){Not_Found();}
//站点设置和站点图标
$site = unserialize(get_db('user_config','v',['uid'=>UID,'k'=>'s_site']));
$favicon = ( !empty($site['site_icon_file'])) ? $site['site_icon'] : './favicon.ico';
$site['Title'] = $site['title'].(empty($site['subtitle'])?'':' - '.$site['subtitle']);
//免费用户请保留版权,谢谢!
$copyright = empty($global_config['copyright'])?'<a target="_blank" href="https://gitee.com/tznb/twonav">Copyright © TwoNav</a>':$global_config['copyright'];
$ICP = empty($global_config['ICP'])?'':'<a target="_blank" href="https://beian.miit.gov.cn">'.$global_config['ICP'].'</a>';
$favicon = ( !empty($site['site_icon_file'])) ? $site['site_icon'] : './favicon.ico';
//取登录状态
$is_login = is_login();
@@ -39,7 +42,6 @@ if(!$is_login){
$pv = empty($share['pwd']) || $_SESSION['verify']['share'][$share['id']] == $share['pwd'];
}
}
//判断链接是否停用/私有
if($link['status'] == 0){
@@ -64,7 +66,6 @@ if(!$is_login){
exit('很抱歉,页面所属的祖分类是私有的!您无权限查看,如果您是管理员,请先登录!');
}
//判断链接是否加密
if(!empty($link['pid'])){
$verify_type = 'link_pwd';
@@ -94,9 +95,6 @@ if(!$is_login){
}
}
//取模板信息
require DIR ."/system/templates.php";
$dir_path = DIR.'/templates/transit/'.$s_templates['transit'];
@@ -107,21 +105,15 @@ if(!is_file($transit_path)){
$transit_path= DIR.'/templates/transit/default/index.php';
}
//免费用户请保留版权,谢谢!
$copyright = empty($global_config['copyright'])?'<a target="_blank" href="https://gitee.com/tznb/twonav">Copyright © TwoNav</a>':$global_config['copyright'];
$ICP = empty($global_config['ICP'])?'':'<a target="_blank" href="https://beian.miit.gov.cn">'.$global_config['ICP'].'</a>';
//统计点击数
write_user_count(date('Ym'),'click_Ym');
write_user_count(date('Ymd'),'click_Ymd');
update_db("user_links", ["click[+]"=>1],['uid'=>UID,'lid'=>$id]);
//读取过渡页设置
$transition_page = unserialize(get_db("user_config","v",["t"=>"config","k"=>"s_transition_page","uid"=>UID]));
//读取用户主题配置
$theme_config_db = unserialize(get_db('user_config','v',['t'=>'theme','k'=>$s_templates['transit'],'uid'=>UID]));
$theme_config_db = unserialize(get_db('user_config','v',['t'=>'theme_transit','k'=>$s_templates['transit'],'uid'=>UID]));
//读取默认主题配置
$theme_info = json_decode(@file_get_contents($dir_path.'/info.json'),true);
@@ -143,24 +135,24 @@ if(!empty($link['url_standby'])) {
exit;
}
if ($s_site['link_model'] == '302'){ //302重定向
if ($site['link_model'] == '302'){ //302重定向
header("HTTP/1.1 302 Moved Permanently");
header("Location: ".$link['url']);
exit;
}elseif($s_site['link_model'] == '301'){ //301重定向
}elseif($site['link_model'] == '301'){ //301重定向
header("HTTP/1.1 301 Moved Permanently");
header("Location: ".$link['url']);
exit;
}elseif($s_site['link_model'] == 'Privacy'){ //隐私保护_header
}elseif($site['link_model'] == 'Privacy'){ //隐私保护_header
header("Content-type: text/html; charset=utf-8");
header("Refresh:0;url=".$link['url']);
echo '<html lang="zh-ch"><head><title>正在保护您的隐私..</title><meta name="referrer" content="same-origin"></head>';
exit;
}elseif($s_site['link_model'] == 'Privacy_js'){ //隐私保护_js
}elseif($site['link_model'] == 'Privacy_js'){ //隐私保护_js
header("Content-type: text/html; charset=utf-8");
echo '<html lang="zh-ch"><head><title>正在保护您的隐私..</title><meta name="referrer" content="same-origin"><script>window.location.href="'.$link['url'].'"</script></head>';
exit;
}elseif($s_site['link_model'] == 'Privacy_meta'){ //隐私保护_meta
}elseif($site['link_model'] == 'Privacy_meta'){ //隐私保护_meta
header("Content-type: text/html; charset=utf-8");
echo '<html lang="zh-ch"><head><title>正在保护您的隐私..</title><meta name="referrer" content="same-origin"><meta http-equiv="refresh" content="0;url='.$link['url'].'"></head>';
exit;
+6 -6
View File
@@ -1,10 +1,9 @@
<?php if(!defined('DIR')){header('HTTP/1.1 404 Not Found');header("status: 404 Not Found");exit;}
//主页入口
define('is_login',is_login());
//var_dump($global_config['offline']);
//判断用户组,是否允许未登录时访问主页
if(!is_login && !check_purview('Common_home',1)){
if(!is_login && ($global_config['Privacy'] == 1 || !check_purview('Common_home',1))){
header("HTTP/1.1 302 Moved Permanently");
header("Location: ./?c=admin");
exit;
@@ -44,7 +43,7 @@ $support_category_svg = $theme_info['support']['category_svg']??0; //0.不支持
//主题配置(默认)
$theme_config = empty($theme_info['config']) ? []:$theme_info['config'];
//主题配置(用户)
$theme_config_db = get_db('user_config','v',['t'=>'theme','k'=>$theme,'uid'=>UID]);
$theme_config_db = get_db('user_config','v',['t'=>'theme_home','k'=>$theme,'uid'=>UID]);
$theme_config_db = unserialize($theme_config_db);
//合并配置数据
$theme_config = empty($theme_config_db) ? $theme_config : array_merge ($theme_config,$theme_config_db);
@@ -133,10 +132,11 @@ function get_links($fid) {
$where['LIMIT'] = $site['new_link'];
}
$where['ORDER']['lid'] = 'DESC';
//输出上限&不在子页面&例外主题
}elseif($site['max_link'] > 0 && empty(Get('oc')) && !$site['ex_theme']){
//输出上限&不在子页面&例外主题&书签分享
}elseif($site['max_link'] > 0 && empty(Get('oc')) && !$site['ex_theme'] && empty($_GET['share'])){
$count = count_db('user_links',$where);
$where['LIMIT'] = $site['max_link'];
$max_link = true;
}
$links = select_db('user_links',['lid(id)','fid','property','title','url(real_url)','url_standby','description','icon','click','pid'],$where);
foreach ($links as $key => $link) {
@@ -173,7 +173,7 @@ function get_links($fid) {
//获取图标链接
$links[$key]['ico'] = $lock ? $GLOBALS['libs'].'/Other/lock.svg' : geticourl($site['link_icon'],$link);
}
if($site['max_link'] > 0 && $count > $site['max_link'] && empty(Get('oc')) && !$site['ex_theme']){
if($max_link && $count > $site['max_link']){
$oc_url = "./index.php?u={$u}&oc={$fid}" . (empty($_GET['theme']) ? '':"&theme={$_GET['theme']}");
array_push($links,['id'=>0,'title'=>'查看全部','url'=>$oc_url,'real_url'=>$oc_url,'description'=>'该分类共有'.$count.'条数据','ico'=>'./favicon.ico']);
}
+5 -7
View File
@@ -155,8 +155,7 @@ function get_db($table,$columns,$where,$rp = []){
//写全局配置(存在则更新,不存在则创建)
function write_global_config($key,$value,$d){
$re = get_db('global_config','k',['k'=>$key]);
if(empty($re)){
if(!has_db('global_config',['k'=>$key])){
insert_db("global_config", ["k" => $key,"v" => $value,"d" => $d]);
}else{
update_db("global_config", ["v" => $value],['k'=>$key]);
@@ -165,17 +164,16 @@ function write_global_config($key,$value,$d){
//写用户配置(存在则更新,不存在则创建)
function write_user_config($key,$value,$t,$d){
$re = get_db('user_config','k',['uid'=>UID,'k'=>$key]);
if(empty($re)){
if(!has_db('user_config',['uid'=>UID,'k'=>$key,'t'=>$t])){
insert_db("user_config", ['uid'=>UID,"k"=>$key,"v"=>$value,"t"=>$t,"d"=>$d]);
}else{
update_db("user_config", ["v"=>$value],['uid'=>UID,'k'=>$key]);
update_db("user_config", ["v"=>$value],['uid'=>UID,'k'=>$key,'t'=>$t]);
}
}
//写用户统计
function write_user_count($key,$t){
$re = get_db('user_count','k',['uid'=>UID,'t'=>$t,'k'=>$key]);
if(empty($re)){
if(!has_db('user_count',['uid'=>UID,'t'=>$t,'k'=>$key])){
insert_db("user_count", ['uid'=>UID,"k"=>$key,"v"=>1,'t'=>$t]);
}else{
update_db("user_count", ["v[+]"=>1],['uid'=>UID,'t'=>$t,'k'=>$key]);
+1 -1
View File
@@ -1 +1 @@
v2.0.12-20230417
v2.0.14-20230420
@@ -58,7 +58,7 @@ if($s['help'] != 'del'|| !count($dbs) || isset($_GET['help'])){
$arr['type'] = '使用说明';
$arr['contact'] = '271152681@qq.com';
$arr['title'] = 'TwoNav 极简留言板';
$arr['content'] = "1.极简留言板采用轻量设计,整体只有几KB\n2.留言数据存放路径/data/user/xxx/MessageBoard/ (xxx表示用户名)\n3.默认是禁止留言的,点击上方蓝色字(禁止留言/允许留言)可切换状态\n4.使用方法: 点击极简留言板(蓝字)>把地址栏的URL复制>在后台添加链接即可\n5.本条信息被删除时如果存在留言则不显示,没有留言时依旧会显示!\n6.有提交长度限制,类型32,联系方式64,标题128,内容2048字节!若不够用请自己修改源代码!\n7.为了防止被恶意提交,当留言数超过256时将不在接收留言!";
$arr['content'] = "1.极简留言板采用轻量设计,整体只有几KB\n2.留言数据存放路径/data/user/xxx/MessageBoard/ (xxx表示用户名)\n3.默认是禁止留言的,点击上方蓝色字(禁止留言/允许留言)可切换状态\n4.使用方法: 点击极简留言板(蓝字)>把地址栏的URL复制>在后台添加链接即可(部分主题已支持自动展现入口)\n5.本条信息被删除时如果存在留言则不显示,没有留言时依旧会显示!\n6.有提交长度限制,类型32,联系方式64,标题128,内容2048字节!若不够用请自己修改源代码!\n7.为了防止被恶意提交,当留言数超过256时将不在接收留言!";
$arr['time'] = date("Y-m-d H:i:s",time());
$arr['ip'] = '127.0.0.1';
$arr['id'] = $id;
+2 -2
View File
@@ -25,7 +25,7 @@ function echo_text($data){ ?>
<div class="layui-form-item">
<label class="layui-form-label"><?php echo $data['title']?></label>
<div class="layui-input-block">
<input type="text" name="_<?php echo $data['name']?>" autocomplete="off" value="<?php echo $data['value']?>" class="layui-input">
<input type="text" name="_<?php echo $data['name']?>" autocomplete="off" value="<?php echo htmlentities($data['value'])?>" class="layui-input">
</div>
</div>
<?php
@@ -35,7 +35,7 @@ function echo_textarea($data){ ?>
<div class="layui-form-item">
<label class="layui-form-label"><?php echo $data['title']?></label>
<div class="layui-input-block">
<textarea name="_<?php echo $data['name']?>" class="layui-textarea"><?php echo $data['value']?></textarea>
<textarea name="_<?php echo $data['name']?>" class="layui-textarea"><?php echo htmlentities($data['value'])?></textarea>
</div>
</div>
<?php
+11
View File
@@ -123,6 +123,17 @@ $title='系统设置';require(dirname(__DIR__).'/header.php');
</div>
<div class="layui-form-mid layui-word-aux">开启时将关闭主页/登录/注册等服务,站长账号不受影响(网站升级迁移时适用)</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label required">强制私有</label>
<div class="layui-input-inline">
<select name="Privacy">
<option value="0" selected="">依用户组配置</option>
<option value="1" >全站用户</option>
</select>
</div>
<div class="layui-form-mid layui-word-aux">开启后用户必须登录才可以进入主页(过渡页不限制)</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label required">二级域名</label>
+3
View File
@@ -1,6 +1,9 @@
<?php
if($USER_DB['UserGroup'] != 'root'){$content='您没有权限访问此页面'; require(DIR.'/templates/admin/page/404.php');exit;}
$title='站长工具';
if(function_exists("opcache_reset")){
opcache_reset(); //清理PHP缓存
}
require(dirname(__DIR__).'/header.php');
?>
<style>
-1
View File
@@ -51,7 +51,6 @@ $HTTP_HOST = preg_replace('/:\d+$/','',$_SERVER['HTTP_HOST']); //去除端口号
<button class="layui-btn" lay-submit lay-filter="get_subscribe">查询授权</button>
</div>
<fieldset class="layui-elem-field layui-field-title" style="margin-top:30px;"><legend>授权用户专享</legend></fieldset>
<blockquote class="layui-elem-quote layui-text">
<li>1. 可使用一键更新功能</li>
+2 -2
View File
@@ -200,7 +200,7 @@ layui.use(['form','table','laydate','tableSelect'], function () {
,{field:'id',title:'ID',width:60,sort:true,hide:true}
,{title: '操作',toolbar: '#tablebar',align:'center',width:140}
,{field:'sid',title:'标识',width:118,align:'center',templet:function(d){
return '<a style="color:#3c78d8" href = "./index.php?share='+d.sid+'" target = "_blank" title = "点击打开">'+d.sid+'</a>';
return '<a style="color:#3c78d8" href = "./index.php?u='+u+'&share='+d.sid+'" target = "_blank" title = "点击打开">'+d.sid+'</a>';
}}
,{field:'name',title:'名称',width:180}
,{field:'pwd',title:'提取码',width:160}
@@ -331,7 +331,7 @@ layui.use(['form','table','laydate','tableSelect'], function () {
});
}else if(obj.event === 'copy'){
if(isSupported){
ClipboardJS.copy(baseUrl + "index.php?share=" + data.sid +(data.pwd != '' ? '&pwd=' + data.pwd:''));
ClipboardJS.copy(baseUrl + "index.php?u="+u+"&share=" + data.sid +(data.pwd != '' ? '&pwd=' + data.pwd:''));
layer.msg('复制成功', {icon: 1});
}else{
layer.msg('复制失败,浏览器不支持', {icon: 5});
+22
View File
@@ -2,6 +2,28 @@
<body>
<div class="layuimini-container">
<div class="layuimini-main" style=" margin-left: 20px;">
<li class="layui-timeline-item">
<i class="layui-icon layui-timeline-axis"></i>
<div class="layui-timeline-content layui-text">
<h4 class="layui-timeline-title">v2.0.14-20230420</h4>
<ul>
<li>修复书签分享和输出上限冲突的问题</li>
<li>[数据库更新]修复不同类型的模板目录名相同时存在窜数据的问题</li>
</ul>
</div>
</li>
<li class="layui-timeline-item">
<i class="layui-icon layui-timeline-axis"></i>
<div class="layui-timeline-content layui-text">
<h4 class="layui-timeline-title">v2.0.13-20230418</h4>
<ul>
<li>修复链接模式不受控的问题(上个版本造成)</li>
<li>网站管理/系统设置新增强制私有选项</li>
<li>修复书签分享的链接可能无法访问</li>
<li>修复扩展字段输入html代码可能造成页面渲染异常的问题</li>
</ul>
</div>
</li>
<li class="layui-timeline-item">
<i class="layui-icon layui-timeline-axis"></i>
<div class="layui-timeline-content layui-text">