-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjserrorreporter.php
executable file
·202 lines (178 loc) · 6.62 KB
/
jserrorreporter.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
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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
<?php
session_start();
if (!(isset($_SESSION['login']) && $_SESSION['login'] != '')) {
header("Location: /dashboard/login");
}
else
{
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="error details">
<title>scalabrine | JavaScript Error Reporting Demo</title>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="/img/favicon.ico" type="image/x-icon" />
<!-- Bootstrap core CSS -->
<link href="/dashboard/css/bootstrap.min.css" rel="stylesheet">
<link href="/dashboard/css/bootstrap-reset.css" rel="stylesheet">
<!--external css-->
<link href="/dashboard/assets/font-awesome/css/font-awesome.css" rel="stylesheet" />
<!-- Custom styles for this template -->
<link href="/dashboard/css/style.css" rel="stylesheet">
<link href="/dashboard/css/style-responsive.css" rel="stylesheet" />
<!-- HTML5 shim and Respond.js IE8 support of HTML5 tooltipss and media queries -->
<!--[if lt IE 9]>
<script src="js/html5shiv.js"></script>
<script src="js/respond.min.js"></script>
<![endif]-->
<script src="errorreporter.php" type="text/javascript"></script>
<script type="text/javascript">
/* scripts that may trigger errors */
function badCode()
{
alert('Good code running when suddenly...');
abooM('bad code!'); /* BAD CODE ON PURPOSE */
que;
ambd('ello');
}
</script>
</head>
<body>
<div id="container" >
<!--header start-->
<header class="header white-bg">
<div class="sidebar-toggle-box">
<div data-original-title="Toggle Navigation" data-placement="right" class="icon-reorder tooltips"></div>
</div>
<!--logo start-->
<a href="/dashboard/index" class="logo"><span>scalabrine</span></a>
<!--logo end-->
<div class="nav notify-row" id="top_menu">
<!-- notification start -->
<a>
<i class="icon-bell-alt"></i>
last logged in: <?php echo $_SESSION['time'] ?>
<br>
<i class="icon-envelope"></i>
current user's email: <?php echo $_SESSION['email'] ?>
</a>
</div>
<div class="top-nav ">
<!--user start-->
<ul class="nav pull-right top-menu">
<!-- user login dropdown start-->
<li class="dropdown">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">
<img alt="" src="/dashboard/img/user.png" />
<span class="username"><?php echo $_SESSION['username'] ?></span>
<b class="caret"></b>
</a>
<ul class="dropdown-menu extended logout">
<li class="log-arrow-up"></li>
<li><a href="#"><i class="icon-cog"></i> Settings</a></li>
<li><a href="/dashboard/logout"><i class="icon-key"></i> Log Out</a></li>
</ul>
</li>
<!-- user login dropdown end -->
</ul>
</div>
</header>
<!--header end-->
<!--sidebar start-->
<aside>
<div id="sidebar" class="nav-collapse ">
<!-- sidebar menu start-->
<ul class="sidebar-menu" id="nav-accordion">
<li>
<a href="/dashboard/index">
<i class="icon-dashboard"></i>
<span>dashboard</span>
</a>
</li>
<!--
<li>
<a href="/dashboard/error_detail">
<i class="icon-tasks"></i>
<span>error details</span>
</a>
</li>
-->
<li>
<a href="/crud/index">
<i class="icon-gear"></i>
<span>user management</span>
</a>
</li>
<li>
<a class="active" href="/jserrorreporter">
<i class="icon-exclamation"></i>
<span> error reporter</span>
</a>
</li>
<li>
<a href="/dashboard/config">
<i class="icon-file"></i>
<span>error tracking script</span>
</a>
</li>
<!--
<li>
<a href="/index">
<i class="icon-user"></i>
<span>home</span>
</a>
</li>
-->
</ul>
<!-- sidebar menu end-->
</div>
</aside>
<!--sidebar end-->
<!--main content start-->
<div id="crud-main-content">
<div class="wrapper">
<div class="row">
<h3>Locally Test the Error Tracking Service</h3>
<br>
<form action="#">
<label>Do you dare press it?
<button class="btn btn-success" type="submit" onclick="badCode();" >Uh oh</button>
</label>
</form>
<br /><br />
</div>
</div>
</div>
<!-- /container -->
<!--main content end-->
<!--footer start-->
<footer class="site-footer">
<div class="text-center">
2014 © scalabrine.
<a href="#" class="go-top">
<i class="icon-angle-up"></i>
</a>
</div>
</footer>
<!--footer end-->
</div>
<?php
}
?>
<!-- js placed at the end of the document so the pages load faster -->
<script src="/dashboard/js/jquery-1.8.3.min.js"></script>
<script src="/dashboard/js/bootstrap.min.js"></script>
<script src="/dashboard/js/jquery.dcjqaccordion.2.7.js"></script>
<script src="/dashboard/js/jquery.scrollTo.min.js"></script>
<script src="/dashboard/js/jquery.nicescroll.js"></script>
<script src="/dashboard/js/jquery.sparkline.js"></script>
<script src="/dashboard/assets/advanced-datatable/media/js/jquery.dataTables.js"></script>
<script src="/dashboard/js/jquery.customSelect.min.js" ></script>
<script src="/dashboard/js/respond.min.js" ></script>
<!--common script for all pages-->
<script src="/dashboard/js/common-scripts.js"></script>
</body>
</html>