1 Star 2 Fork 2

Andy/短网址程序源码

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
index.php 6.00 KB
一键复制 编辑 原始数据 按行查看 历史
Andy 提交于 2019-12-16 16:20 . init
<?php
if (!(include "functions/database.php")) {
echo "<a href='install/index.html'>Please Install the script first or make sure it is installed correctly.</a>";
exit;
}
include "functions/count.php";
$data = $db->query("SELECT * FROM settings");
$info = $db->fetch_array($data);
$ads = $db->query("SELECT * FROM ads");
$ads_info = $db->fetch_array($ads);
?>
<!DOCTYPE html>
<html class="full" lang="zh-CN">
<head>
<base href="<?php echo $info['URL']; ?>/" />
<meta charset="utf-8">
<title><?php echo $info['name']; ?></title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="吉他郭短网址生成">
<meta name="author" content="AndyGuo">
<?php
$logo_url = $info['logo_url'];
if (strpos($logo_url,";")) {
$logo_url = explode(";",$logo_url);
if (empty($logo_url[1])) {
$logo_url[1] = $logo_url[0];
}
} else {
$logo_url = [$logo_url,$logo_url];
}
$logo_tag = "";
if ($info['logo_type'] == 1) {
$logo_tag = "<meta property=\"og:image\" content='$logo_url[0]'>";
}
echo $logo_tag;
?>
<!-- Bootstrap core CSS -->
<link href="css/bootstrap.css" rel="stylesheet">
<link href="css/animate.css" rel="stylesheet">
<!-- Custom CSS for the Template -->
<link href="css/style.css" rel="stylesheet">
<link href="https://lib.baomitu.com/font-awesome/5.4.1/css/all.min.css" rel="stylesheet">
<style>
<?php echo $info['cstm-style']; ?>
</style>
</head>
<body>
<?php
include "functions/menu.php";
?>
<div class="container">
<div class="row logo">
<div class="col-lg-12" style="text-align:center">
<?php
include "functions/logo.php";
include "functions/darkmode.php";
?>
</div>
</div>
</div>
<div class="container animated fadeIn" style="max-width: 950px;">
<form action="create.php" method="POST" enctype="multipart/form-data">
<div class="row">
<div class="col-lg-12">
<div class="input-group">
<input id="urlbox" class="form-control cz-shorten-input" placeholder="http://" name="longurl" type="text" data-validation-error-msg=" ">
<span class="input-group-btn">
<button class="btn btn-large btn-primary cz-shorten-btn" type="submit" id="submit"> 缩 短</button>
</span>
</div>
</div>
</div>
<div class="row" style="margin-top: 8px;">
<div class="col-lg-6">
<div class="input-group" style="margin-top: 2px;">
<span class="input-group-addon"><?php echo $info['URL']; ?>/</span>
<input type="text" id="cust" data-validation="alphanumeric" data-validation-allowing="-_" data-validation-optional="true" data-validation-error-msg=" " name="cust" class=" span5 form-control" placeholder="自定义链接(可选)">
</div>
</div>
<div class="col-lg-6" style="margin-top: 2px;">
<div class="input-group">
<span class="input-group-addon"><i class="fa fa-lock"></i></span>
<input type="text" data-validation="alphanumeric" data-validation-allowing="-_" data-validation-optional="true" data-validation-error-msg=" " id="pass" name="pass" class="form-control" placeholder="密码(可选)">
</div>
</div>
</div>
</form>
<div class="row" style="">
<div class="col-lg-12" style="text-align: center; margin-top: 20px;">
<?php echo '' . $ads_info['ad1'] . ''; ?>
</div>
</div>
<div class="row" style="margin-top: 30px;" >
<div class="col-lg-4 text-center">
<div class="panel panel-default">
<div class="panel-body">
<h2 class="newsize" style="font-weight:bolder;"> 总点击量 </h2>
<h2 class="newsize" style="letter-spacing:1px;"><?php echo $num_rows3; ?></h2>
</div>
</div>
</div>
<div class="col-lg-4 text-center">
<div class="panel panel-default">
<div class="panel-body">
<h2 class="newsize" style="font-weight:bolder;"> 总压缩量 </h2>
<h2 class="newsize" style="letter-spacing:1px;"><?php echo $num_rows1; ?></h2>
</div>
</div>
</div>
<div class="col-lg-4 text-center">
<div class="panel panel-default">
<div class="panel-body">
<h2 class="newsize" style="font-weight:bolder;"> 今日压缩 </h2>
<h2 class="newsize" style="letter-spacing:1px;"><?php echo $num_rows2; ?></h2>
</div>
</div>
</div>
</div>
</div>
<!-- JavaScript -->
<script src="js/jquery-1.10.2.js"></script>
<script src="js/bootstrap.js"></script>
<script src="js/jquery.form-validator.min.js"></script>
<script>
$.validate({
modules: 'security'
});
</script>
</body>
</html>
<?php $db->close_connection(); ?>
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
PHP
1
https://gitee.com/andy5525/short_url.git
git@gitee.com:andy5525/short_url.git
andy5525
short_url
短网址程序源码
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385