diff check_sections_details.php @ 12:7e04cbe8b2a0

add required libraries to server
author Zoe Hong <zhong@mpiwg-berlin.mpg.de>
date Wed, 24 Jun 2015 11:11:31 +0200
parents 0a03c75499e6
children 3d206aa0c77d
line wrap: on
line diff
--- a/check_sections_details.php	Mon Jun 22 15:12:58 2015 +0200
+++ b/check_sections_details.php	Wed Jun 24 11:11:31 2015 +0200
@@ -105,7 +105,7 @@
     $user_info = json_decode($output, true);
 	$current_editor = (string)$user_info['userName'];
 	
-	if ($current_editor == null) {
+	if ($current_editor == null || strcmp($user_info['status'], "error") == 0) {
 		// redirect to LGServices homepage
 		header("Location: "+$lgserver_url+"LGServices");
 		//header('Location: http://localgazetteers/LGServices');
@@ -118,18 +118,28 @@
 	//header('Location: http://localgazetteers/LGServices');
 }
 
+
 ?>
 
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
 <html>
     <head>
             <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
-            <link href="https://code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css" type="text/css" rel="stylesheet"/>
+
+            <link href="css/jquery-ui/jquery-ui.css" type="text/css" rel="stylesheet"/>
+           	<script src="js/jquery/1.6.2/jquery.min.js" type="text/javascript"></script>
+            <script src="js/jquery/jquery-ui.js" type="text/javascript"></script>
+        
             <link href="css/check_sections.css" type="text/css" rel="stylesheet"/>
-            <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" type="text/javascript"></script>
             <script src="js/check_sections_details.js" type="text/javascript"></script>
+            	
+			<!--
+			<link href="https://code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css" type="text/css" rel="stylesheet"/>
+           	<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" type="text/javascript"></script>
             <script src="https://code.jquery.com/ui/1.10.4/jquery-ui.js" type="text/javascript"></script>
+          	-->
             <!--<script src="js/check_sections.js" charset="utf-8"></script>!-->
+
     </head>
     <body>
 		<div id="loading">...</div>
@@ -233,6 +243,32 @@
 		}
 	
 
+		/*
+		// --- timeout reminder ---
+		var timeoutID;
+		delayedAlert();
+		function delayedAlert() {
+		 	timeoutID = window.setTimeout(slowAlert, 4000);
+		}
+		function slowAlert() {
+		 	if (confirm("Reminder: It's been 30 mins. Don't forget to save your work. \n\nKeep working? \n(Press Cancel will turn off this reminder.)")) {
+		 		timeoutID = window.setTimeout(slowAlert, 4000);
+		 		// renew session?
+		 		
+				var lg_url = "<?php echo $lgserver_url?>" + "rest/utils/getUser?sessionId=" + session_id;
+				console.log(lg_url);
+
+		 		$.post(lg_url, function(data) {
+
+					///console.log(data);
+
+		 		});
+		 	}
+		}
+		*/
+
+
+
 		</script>