-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdashboard.php
60 lines (53 loc) · 2.47 KB
/
dashboard.php
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
<?php
include "./library/security.php";
include "./library/autoload.php";
$user = new User();
$user->set_details_from_database($_SESSION["username"]);
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Dashboard</title>
<link rel="stylesheet" href="./css/dist/css/bootstrap.min.css">
<link rel="stylesheet" href="./css/stylesheet_1.css" >
<script src="./js/jquery.js"></script>
<script src="./css/dist/js/bootstrap.min.js"></script>
<script src="./js/script_1.js"></script>
</head>
<body>
<?php include "navigation.php";?>
<!-- Form for redirecting -->
<form id="operation" method="post">
<input name="action" type="hidden" value="" />
</form>
<main class="row container">
<!-- Left pane -->
<div class="col-sm-2">
<figure style="margin-bottom: 5px;">
<img src="<?php echo $user->get_image();?>" alt="User Image"
width="150" height="150" class="img-thumbnail" />
</figure>
<span class="large-font-1-2"><?php echo $user->get_name();?></span>
<br />
<br />
<button class="btn btn-default btn-block large-font-1-2" onclick="recentPosts()">Recent Posts</button>
<button class="btn btn-default btn-block large-font-1-2" onclick="redirect('new', 'writer.php')">New Post</button>
<button class="btn btn-default btn-block large-font-1-2" onclick="getMyPosts()">My Posts</button>
<button class="btn btn-default btn-block large-font-1-2" onclick="redirect('new', 'newdiscussion.php')">New Discussion</button>
<button class="btn btn-default btn-block large-font-1-2" onclick="viewDiscussionList()">View Discussions</button>
<button class="btn btn-default btn-block large-font-1-2" onclick="myDiscussions()">My Discussions</button>
</div>
<!-- Middle Column -->
<div class="col-sm-8">
<div id="display-container">
<div class="nothing">Nothing to display</div>
</div>
</div>
<script>
recentPosts();
</script>
</main>
</body>
</html>