summaryrefslogtreecommitdiff
path: root/index.html
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2014-09-17 21:04:40 (GMT)
committerChristian Pointner <equinox@helsinki.at>2014-09-17 21:04:40 (GMT)
commit364cc862cb1de447b85396fed616477c4f85f755 (patch)
tree06fcad1d6ab2a8ff9b11ba19eeae30380c87d966 /index.html
parentfda69ffb749b140938acd373ff78600b2085fef1 (diff)
fixed json syntax error
Diffstat (limited to 'index.html')
-rw-r--r--index.html6
1 files changed, 5 insertions, 1 deletions
diff --git a/index.html b/index.html
index a07f16d..e7c7cd9 100644
--- a/index.html
+++ b/index.html
@@ -7,7 +7,11 @@
<script src="/javascript/jquery/jquery.min.js"></script>
<script type="text/javascript">
function authSuccess(data) {
- alert("username: " + data.username + "\ntoken: " + data.token );
+ if (data.status == 'ERROR') {
+ alert("login error: " + data.errorstring);
+ } else {
+ alert("username: " + data.username + "\ntoken: " + data.token );
+ }
}
function authError(req, status, error) {