-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmessage_show.php
More file actions
97 lines (91 loc) · 3.43 KB
/
message_show.php
File metadata and controls
97 lines (91 loc) · 3.43 KB
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
<?php
if(!isset($_SESSION))
{
session_start();
}
header("Content-Type: text/html; charset=utf-8");
$_POST['position'] = "綠色行動";
require_once("connMysql.php");
include_once("locaction.php");
?>
<!DOCTYPE html>
<html lang="zh-Hant-TW">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, minimal-ui initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no">
<title>綠色行動</title>
<!-- <link rel="stylesheet" href="css/reset.css"> -->
<link rel="stylesheet" href="css/index.css">
<link rel="stylesheet" href="css/font-awesome.min.css">
<link rel="stylesheet" href="css/dropmenu.css">
<link rel="stylesheet" type="text/css" href="css/message.css">
</head>
<body>
<nav id="menu" class="left">
<ul>
<li><a href="index.php"><i class="fa fa-hoff-canvas Sime"></i>首頁</a></li>
<li>
<a href="#"><i class="fa fa-laptop"></i>展區介紹<i class="fa fa-caret-down"></i></a>
<ul>
<li><a href="area1.php">我們只有一個地球</a></li>
<li><a href="area2-1.php">尋找x點</a></li>
<li><a href="area3.php">書寫自然</a></li>
<li><a href="area4.php">行動歌詩</a></li>
<li>
<a href="#"><i class="fa fa-tree"></i>綠色行動<i class="fa fa-caret-down"></i></a>
<ul>
<li><a href="message.php">綠色行動</a></li>
<li><a href="message_show.php">綠色樹</a></li>
</ul>
</li>
</ul>
</li>
<li><a href="feedback.php"><i class="fa fa-info-circle"></i>意見回饋</a></li>
<li><a href="about.php"><i class="fa fa-users"></i>聯絡資訊</a></li>
</ul>
<a href="#" id="showmenu"> <i class="fa fa-bars fa-1x"></i> </a> <!--選單按鈕-->
</nav>
<div id="bgpic">
<div id="mid-conent">
<br>
<h1>綠色行動</h1>
</div>
</div>
<div class="messagecontainer" id="scrollbar">
<div class="messagebox" style=" margin-top: 0px;">
<?php
$query = mysql_query("SELECT * FROM `message` WHERE 1");
$index = 1;
while ($run=mysql_fetch_array($query)) {
$impression = $run['impression'];
$green_action = $run['green_action'];
$time = $run['time'];
$day = $run['day'];
echo "<hr>
<h4>留下你印象深刻的文句,並與我們分享</h4>
<p name=\"impression\">$impression</p>
<h4>你的「綠色行動」是什麼?</h4>
<p name=\"green_action\">$green_action</p>
<p id=\"time\" name=\"time\">$day $time</p>";
$index++;
}
?>
</div>
</div>
<script src="js/jquery-2.1.1.min.js"></script>
<script>
/*menu*/
$("#showmenu").click(function (e) { //點擊選單按鈕時
e.preventDefault(); //停止
$("#menu").toggleClass("show"); //在#menu增加Class
});
$("#menu a").click(function (event) {
// event.preventDefault();
if ($(this).next('ul').length) {
$(this).next().toggle('fast');
$(this).children('i:last-child').toggleClass('fa-caret-down fa-caret-left'); //展開子選單時改變Class
}
});
</script>
</body>
</html>