-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlist.htm
97 lines (93 loc) · 3.08 KB
/
list.htm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv=refresh content="60">
<title>查看话题</title>
<style type="text/css">
.floatl{float:left;}
.clear{clear:both;}
.title{ padding-left:100px; margin-top:5px;}
.width{ width:350px;}
.margintop{ margin-top:10px;}
.marginleft{ margin-left:50px;}
.marginright{ margin-right:300px;}
.submit{ margin:10px 0 0 500px;}
textarea{width:490px; height:50px;}
.content{ margin:0 auto; width:908px;}
.top{ position:fixed; border:1px solid black; text-decoration: none; top:500px; left:1200px;}
.center{height: 100%;}
.backlist{display: none;}
li{list-style: none;}
</style>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.0/jquery.min.js"></script>
</head>
<body>
<?php include 'head.php' ?>
<!--发表留言部分-->
<div class="center">
<a href="#top" class="top"> top </a>
<form class="content" action="list.php" method="post" onsubmit="return chenck();" name="title">
<fieldset>
<legend>发表话题</legend>
<div class="title">
<span class="floatl">发布话题:</span><input class="floatl width marginright" type="text" name="tcontent" /><br/>
<span class="floatl margintop">话题详述:</span><textarea class="floatl margintop" name="content" cols="50" rows="3"></textarea>
<br/>
<input class="clear floatl submit" type="submit" name="tsubmit" value="发布话题"/>
</div>
</fieldset>
</form>
<!--查看留言部分-->
<div class="content margintop">
<fieldset>
<legend>查看话题</legend>
<div class="session">
<ul>
<?php
while($result=mysql_fetch_array($fcontent)){
?>
<li>
<fieldset>
<legend><?php echo $result['UName']?>说:</legend>
<a class="marginleft" href="session.php?ID=<?php echo $result['ID'] ?>"><?php echo $result['Title']?></a><br/>
<span class="submit">回帖数<?php echo $result['Click']?></span> <span>时间<?php echo $result['Time']?></span>
</fieldset>
</li>
<?php } ?>
</ul>
</div>
</fieldset>
</div>
</div>
<?php include 'footer.php' ?>
</body>
</html>
<script type="text/javascript">
function chenck()
{
if(title.tcontent.value=="")
{
alert("话题内容不得为空");
title.tcontent.focus();
return false;
}
if(title.content.value=="")
{
alert("内容不得为空");
title.content.focus();
return false;
}
}
$(document).ready(
function()
{
if ($(".center").height()<=550)
{
var footercss={position:'absolute',bottom:'0px',background:'#FFF',width:'99%'};
var topcss={display:'none'};
$(".footer").css(footercss);
$(".top").css(topcss);
}
});
</script>