代码拉取完成,页面将自动刷新
<?php
// 作者:黑色童年
// qq :2104819695
//微信:laobiaoz
//尊重版权!谢谢删版权死妈
include ("config.php");
//作者:黑色童年
$title = "Pink岛";
$gjc = "Pink岛";
$nr = "Pink岛信息列表";
$key = $_POST['key'];
//判断如果他的值是空值的话直接跳转到到首页
if($key == null){
echo '<script>window.location.assign("index.php")</script>';
}
mysqli_query($conn, "set id 'utf-8'");//查询语句设置字符集
$sql = "select * from list where name like '%". $key ."%'"; //查询语句
//$sql =$conn->query("SELECT * FROM" . xxx . "_xxx WHERE xingming LIKE '%{$keywords}%'");
$result=mysqli_query($conn,$sql);
if(!$result){
die('无法读取数据,:'.mysqli_error($conn));
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title><?php echo $title ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="<?php echo $gjc?>">
<meta name="keywords" content="<?php echo $gjc?>">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<link href="./css/stye.css" rel="stylesheet">
<style>
.imga{
width: 30px;
vertical-align:middle;
}
.xixi{
box-shadow:
2.8px 2.8px 2.2px rgba(0, 0, 0, 0.02),
6.7px 6.7px 5.3px rgba(0, 0, 0, 0.028),
12.5px 12.5px 10px rgba(0, 0, 0, 0.035),
22.3px 22.3px 17.9px rgba(0, 0, 0, 0.042),
41.8px 41.8px 33.4px rgba(0, 0, 0, 0.05),
100px 100px 80px rgba(0, 0, 0, 0.07)
;
}
</style>
</head>
<body >
<div class="cleaarfix header">
<div class="main-container">
<div class="website clearfix"><a href="index.php" style="color: pink;font-size: 20px; text-align: center">你搜索的是: <h3><?php echo $key?> </h3></a>
</span></div>
<div class="logo">
</div>
</div>
</div>
<br>
<?php
while($row = $result->fetch_assoc()) {
// 判断人物形象
// 作者:黑色童年
if ($row['xx'] == 1) {
$a = "<img src='./css/01.png' class='imga' />";
} elseif ($row['xx'] == 2) {
$a = "<img src='./css/02.png' class='imga' />";
} elseif ($row['xx'] == 3) {
$a = "<img src='./css/03.png' class='imga' />";
} elseif ($row['xx'] == 4) {
$a = "<img src='./css/04.png' class='imga' />";
} elseif ($row['xx'] == 5) {
$a = "<img src='./css/05.png' class='imga' />";
} else {
$a = "<img src='./css/06.png' class='imga' />";
};
?>
<div class="xixi"> <?php echo $a ?>
<a style="font-size: 15px"> 匿名用户: </a>
<h6 style="">发布时间:<?php echo $row['sj'] ?></h6>
<h4 style="margin-left: 35px;margin-bottom: 10px" ><br><?php echo $row['content'] ?></h4><hr color="pink"> </div></br>
<?php
}
?>
<!-- 搜索框-->
</body>
<script>
//
// window.sessionStorage=function (){
// alert("===onbeforeunload===");
// if(event.clientX>document.body.clientWidth && event.clientY < 0 || event.altKey){
// alert("你关闭了浏览器");
// }else{
// alert("你正在刷新页面");
// }
// }
</script>
</html>
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。