mirror of https://github.com/helloxz/imgurl
pull/5/head
parent
02bb5f4927
commit
e0e337d122
|
@ -0,0 +1,8 @@
|
|||
<?php
|
||||
include_once("../config.php");
|
||||
|
||||
$year = date('Y',time());
|
||||
|
||||
$version = file_get_contents(APP."functions/version.txt");
|
||||
echo "当前版本:".$version."<br />";
|
||||
?>
|
|
@ -4,18 +4,20 @@
|
|||
// 载入类
|
||||
include_once("config.php");
|
||||
|
||||
//获取当前时间
|
||||
$thetime = date('Y-m',time());
|
||||
|
||||
//初始化
|
||||
$domain = $config['domain'];
|
||||
$userdir = $config['userdir'];
|
||||
$sql = "SELECT `id`,`path` FROM `imginfo` WHERE (`dir` = '$userdir' AND `level` < 3) ORDER BY random() LIMIT 12";
|
||||
$sql = "SELECT `id`,`path` FROM `imginfo` WHERE (`dir` = '$userdir' AND `level` < 3 AND `date` LIKE '$thetime%') ORDER BY random() LIMIT 12";
|
||||
$datas = $database->query($sql)->fetchAll();
|
||||
|
||||
?>
|
||||
|
||||
<div class="layui-container" style = "margin-bottom:6em;">
|
||||
<div class="layui-row">
|
||||
<div class="msg"><i class="layui-icon"></i> 此页面随机显示12张图片,刷新页面可重新随机。</div>
|
||||
<div class="msg"><i class="layui-icon"></i> 此页面随机显示本月12张图片,刷新页面可重新随机,如果不显示说明本月暂未上传图片。</div>
|
||||
<div id = "found-img" class = "layui-col-space20">
|
||||
<?php foreach ($datas as $img) {
|
||||
$imgurl = $domain.$img['path'];
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
v1.0(20180502)
|
|
@ -183,4 +183,16 @@ function ipquery(ip){
|
|||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//关于
|
||||
function about(){
|
||||
url = window.location.protocol + '//';
|
||||
url = url + window.location.host + '/';
|
||||
layer.open({
|
||||
title: '关于',
|
||||
type: 2,
|
||||
area: ['240px', '100px'],
|
||||
content: "./about.php"
|
||||
});
|
||||
}
|
|
@ -13,6 +13,6 @@
|
|||
|
||||
<script src="https://cdn.bootcss.com/jquery/2.2.4/jquery.min.js"></script>
|
||||
<script src="../static/layui/layui.js"></script>
|
||||
<script src="../static/embed.js?v=1.0"></script>
|
||||
<script src="../static/embed.js?v=1.0.1"></script>
|
||||
</body>
|
||||
</html>
|
|
@ -17,7 +17,12 @@
|
|||
<dd><a href="senioradmin.php?type=dubious&page=1">可疑图片</a></dd>
|
||||
</dl>
|
||||
</li>
|
||||
<li class="layui-nav-item"><a href="javascript:;">系统设置</a></li>
|
||||
<li class="layui-nav-item layui-nav-itemed">
|
||||
<a href="javascript:;">系统设置<span class="layui-nav-more"></span></a>
|
||||
<dl class="layui-nav-child">
|
||||
<dd><a href="javascript:;" onclick = "about()">关于</a></dd>
|
||||
</dl>
|
||||
</li>
|
||||
<span class="layui-nav-bar" style="top: 157.5px; height: 0px; opacity: 0;"></span></ul>
|
||||
</div>
|
||||
<!-- 左边导航栏END -->
|
Loading…
Reference in New Issue