Web UI for ARGUS server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

349 lines
12 KiB

6 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <?php
  2. function UI_PageHeader(){
  3. global $WEBPath, $Labels, $UserLang;
  4. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  5. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  6. <head>
  7. <meta name="netinsert" content="0.0.1.1.2.5.2">
  8. <meta name="revisit-after" content="1 day">
  9. <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
  10. <title><?=$Labels->GetLabel('_SITE_TITLE_');?></title>
  11. <meta name="description" CONTENT="<?=$Labels->GetLabel('_SITE_DESCRIPT_');?>">
  12. <base href="<?=$WEBPath;?>">
  13. <meta name="robots" content="index, follow"/>
  14. <meta name="keywords" content=""/>
  15. <link rel="stylesheet" type="text/css" href="style/style.css"/>
  16. <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
  17. <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
  18. <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
  19. <link rel="manifest" href="/site.webmanifest">
  20. <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">
  21. <meta name="msapplication-TileColor" content="#da532c">
  22. <meta name="theme-color" content="#ffffff">
  23. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  24. <meta name="viewport" content="width=device-width, initial-scale=1">
  25. <meta name="mobile-web-app-capable" content="yes">
  26. <meta name="apple-mobile-web-app-capable" content="yes">
  27. <style type="text/css">
  28. .flowplayer {
  29. width: 640px;
  30. }
  31. .fullscreen:-webkit-full-screen {
  32. width: auto !important;
  33. height: auto !important;
  34. margin:auto !important;
  35. }
  36. .fullscreen:-moz-full-screen {
  37. width: auto !important;
  38. height: auto !important;
  39. margin:auto !important;
  40. }
  41. .fullscreen:-ms-fullscreen {
  42. width: auto !important;
  43. height: auto !important;
  44. margin:auto !important;
  45. }
  46. .header_ttl{
  47. font: bold 24px;
  48. }
  49. html, body {
  50. font: normal 12px verdana;
  51. margin: 0;
  52. padding: 0;
  53. border: 0 none;
  54. /*overflow: hidden;
  55. height: 100%;*/
  56. background: #202020;
  57. }
  58. #output {
  59. margin-left: 350px;
  60. }
  61. #log {
  62. width: 80%;
  63. height: 100px;
  64. }
  65. #player {
  66. float: left;
  67. }
  68. #controls {
  69. clear: left;
  70. }
  71. p {
  72. margin: 0;
  73. }
  74. .timeInput, .volumeInput {
  75. width: 3em;
  76. }
  77. </style>
  78. </head>
  79. <body class="bgbody"><center><?php
  80. };
  81. function UI_PageHeaderExt($Static_Scoop = '', $Dynamic_Scoop = ''){
  82. global $WEBPath, $Labels, $UserLang;
  83. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  84. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  85. <head>
  86. <meta name="netinsert" content="0.0.1.1.2.5.2">
  87. <meta name="revisit-after" content="1 day">
  88. <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
  89. <title><?=$Labels->GetLabel('_SITE_TITLE_');?></title>
  90. <meta name="description" CONTENT="<?=$Labels->GetLabel('_SITE_DESCRIPT_');?>">
  91. <base href="<?=$WEBPath;?>">
  92. <meta name="robots" content="index, follow"/>
  93. <meta name="keywords" content=""/>
  94. <link rel="stylesheet" type="text/css" href="style/style.css"/>
  95. <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
  96. <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
  97. <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
  98. <link rel="manifest" href="/site.webmanifest">
  99. <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">
  100. <meta name="msapplication-TileColor" content="#da532c">
  101. <meta name="theme-color" content="#ffffff">
  102. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  103. <meta name="viewport" content="width=device-width, initial-scale=1">
  104. <meta name="mobile-web-app-capable" content="yes">
  105. <meta name="apple-mobile-web-app-capable" content="yes">
  106. <!--link rel="stylesheet" type="text/css" href="lib/javascript/extjs/resources/css/ext-all.css"/-->
  107. <link href="lib/javascript/videojs/video-js.css" rel="stylesheet">
  108. <link rel="stylesheet" type="text/css" href="lib/javascript/extjs/resources/css/ext-all-notheme.css"/>
  109. <link rel="stylesheet" type="text/css" href="lib/javascript/extjs/resources/css/xtheme-access.css"/>
  110. <!--link rel="stylesheet" type="text/css" href="lib/javascript/extjs/resources/css/xtheme-blue.css"/-->
  111. <!--link rel="stylesheet" type="text/css" href="lib/javascript/extjs/resources/css/xtheme-gray.css"/-->
  112. <link rel="stylesheet" type="text/css" href="/style/icons/silk.css"/>
  113. <!-- GC -->
  114. <!-- LIBS -->
  115. <script type="text/javascript" src="lib/javascript/jquery/jquery-1.12.4.min.js"></script>
  116. <script type="text/javascript" src="lib/javascript/videojs/videojs-ie8.min.js"></script>
  117. <script type="text/javascript" src="lib/javascript/videojs/videojs-contrib-hls.js"></script>
  118. <script type="text/javascript" src="lib/javascript/videojs/video.js"></script>
  119. <script type="text/javascript" src="lib/javascript/extjs/adapter/jquery/ext-jquery-adapter.js"></script>
  120. <!--script type="text/javascript" src="lib/javascript/extjs/adapter/ext/ext-base.js"></script-->
  121. <script type="text/javascript" src="lib/javascript/extjs/ext-all.js"></script>
  122. <script type="text/javascript" src="lib/javascript/flash/swfobject.js"></script>
  123. <script type="text/javascript" src="lib/javascript/flash/html5video_flash.js"></script>
  124. <script type="text/javascript" src="lib/javascript/moment-2.8.4/moment.min.js"></script>
  125. <script type="text/javascript" src="lib/javascript/vis-4.21.0/dist/vis.min.js"></script>
  126. <link href="lib/javascript/vis-4.21.0/dist/vis-network.min.css" rel="stylesheet" type="text/css"/>
  127. <link href="lib/javascript/vis-4.21.0/dist/vis-timeline-graph2d.min.css" rel="stylesheet" type="text/css"/>
  128. <link rel="stylesheet" type="text/css" href="/style/leaflet.css"/>
  129. <script type="text/javascript" src="lib/javascript/leaflet/leaflet.js"></script>
  130. <!-- ENDLIBS -->
  131. <style type="text/css">
  132. .flowplayer {
  133. width: 640px;
  134. }
  135. .fullscreen:-webkit-full-screen {
  136. width: auto !important;
  137. height: auto !important;
  138. margin:auto !important;
  139. }
  140. .fullscreen:-moz-full-screen {
  141. width: auto !important;
  142. height: auto !important;
  143. margin:auto !important;
  144. }
  145. .fullscreen:-ms-fullscreen {
  146. width: auto !important;
  147. height: auto !important;
  148. margin:auto !important;
  149. }
  150. .header_ttl{
  151. font: bold 24px;
  152. }
  153. html, body {
  154. font: normal 12px verdana;
  155. margin: 0;
  156. padding: 0;
  157. border: 0 none;
  158. /*overflow: hidden;
  159. height: 100%;*/
  160. background: #202020;
  161. }
  162. #output {
  163. margin-left: 350px;
  164. }
  165. #log {
  166. width: 80%;
  167. height: 100px;
  168. }
  169. #player {
  170. float: left;
  171. }
  172. #controls {
  173. clear: left;
  174. }
  175. p {
  176. margin: 0;
  177. }
  178. .timeInput, .volumeInput {
  179. width: 3em;
  180. }
  181. </style>
  182. <?php
  183. if(is_array( $Static_Scoop )){
  184. foreach( $Static_Scoop as $S ) {
  185. echo '<script type="text/javascript" src="lib/javascript/jsapi_static/'. $S . '"></script>';
  186. };
  187. } else {
  188. if($Static_Scoop!=''){
  189. echo '<script type="text/javascript" src="lib/javascript/jsapi_static/'. $Static_Scoop . '"></script>';
  190. };
  191. };
  192. if(is_array( $Dynamic_Scoop )){
  193. foreach( $Dynamic_Scoop as $S ) {
  194. echo '<script type="text/javascript" src="lib/javascript/jsapi_dynamic/'. $S . '"></script>';
  195. };
  196. } else {
  197. if($Dynamic_Scoop!=''){
  198. echo '<script type="text/javascript" src="lib/javascript/jsapi_dynamic/'. $Dynamic_Scoop . '"></script>';
  199. };
  200. };
  201. ?>
  202. </head>
  203. <body><?php
  204. };
  205. function UI_PageBottomExt(){
  206. global $Script_Start_Time, $Labels;
  207. ?>
  208. </body>
  209. </html>
  210. <?php
  211. };
  212. function UI_PageBottom(){
  213. global $Script_Start_Time, $Labels;
  214. ?>
  215. <table width="90%" class="fieldround20">
  216. <tr>
  217. <td class="r_cell" align="center">
  218. <p style="align: center; font-size: 8px" ><?php
  219. $GG_Time = microtime_float() - $Script_Start_Time;
  220. echo $Labels->GetLabel('__PAGEWASGENIN__');
  221. echo ' ' . $GG_Time . ' ';
  222. if( $GG_Time > 2 ) echo $Labels->GetLabel('__SECONDS__');
  223. else echo $Labels->GetLabel('__SECOND__');
  224. ?></p>
  225. </td>
  226. </tr>
  227. </table>
  228. </center>
  229. </body>
  230. </html>
  231. <?php
  232. };
  233. function UI_LoginForm($target = 'login.php'){
  234. global $Labels;
  235. ?>
  236. <form method="Post" action="<?=$target;?>" enctype="multipart/form-data">
  237. <table width="100%" >
  238. <tr><td align="right"><?=$Labels->GetLabel('__LOGIN_ID__');?></td><td><input type="text" name="login"></td></tr>
  239. <tr><td align="right"><?=$Labels->GetLabel('__PASSWORD__');?></td><td><input type="password" name="password"></td></tr>
  240. <tr><td align="right"></td><td><input type="submit" value="<?=$Labels->GetLabel('__LOGIN__');?>"></td></tr>
  241. </table>
  242. </form>
  243. <?php
  244. };
  245. function UI_SideMenu( $ActiveItem = 0 ){
  246. global $Labels, $CUser;
  247. if( $CUser->Data['id'] > 1 ){
  248. switch( $CUser->Data['access'] ){
  249. case 10:
  250. $mnu = array(
  251. '__PROFILE__'=>'/login.php?login=guest',
  252. '__DASHBOARD__'=>'/',
  253. '__SENSORS__'=>'/devices.php',
  254. '__VIDEOS__'=>'/login.php?login=guest',
  255. '__REPORTS__'=>'/login.php?login=guest',
  256. '__SYSCTRL__'=>'/login.php?login=guest',
  257. '__LOGOUT__'=>'/login.php?login=guest'
  258. );
  259. break;
  260. case 0:
  261. default:
  262. $mnu = array(
  263. '__PROFILE__'=>'/login.php?login=guest',
  264. '__DASHBOARD__'=>'/',
  265. '__LOGOUT__'=>'/login.php?login=guest'
  266. );
  267. break;
  268. };
  269. echo '<table width="100%" class="sideMenuBarTable">';
  270. echo '<tr class="sideMenuBarRow"><td class="sideMenuBarCell">' . $CUser->Data['login'] . '(' . $CUser->Data['access'] .')' . '</a></td></tr>';
  271. $index = 1;
  272. foreach( $mnu as $Key=>$Value ){
  273. if( $index == $ActiveItem ){
  274. echo '<tr class="sideMenuBarRow"><td class="sideMenuBarCell"><a href="' . $Value . '">' . $Labels->GetLabel($Key) . '</a></td></tr>';
  275. } else {
  276. echo '<tr class="sideMenuBarRow"><td class="sideMenuBarCell"><a href="' . $Value . '">' . $Labels->GetLabel($Key) . '</a></td></tr>';
  277. };
  278. $index++;
  279. };
  280. echo "</table>";
  281. } else {
  282. ?><table width="100%" class="sideMenuBarTable">
  283. <tr class="sideMenuBarRow"><td class="sideMenuBarCell"></td></tr>
  284. </table><?php
  285. };
  286. };
  287. function UI_MainDashBoard(){
  288. global $Labels, $CUser;
  289. //echo '<img name="main" id="main" border="1" width="640" height="480" src="http://gagua:4GetMyID@192.168.200.116/ISAPI/Streaming/channels/101/picture?videoResolutionWidth=1920&videoResolutionHeight=1080">';
  290. ?>
  291. <div id="mainDashBoard">
  292. </div>
  293. <!--object classid="clsid:9BE31822-FDAD-461B-AD51-BE1D1C159921"
  294. codebase="http://download.videolan.org/pub/videolan/vlc/last/win32/axvlc.cab"
  295. id="vlc"
  296. width = "640px"
  297. height = "480px"
  298. target = "/test_mp4.php"
  299. >
  300. <embed
  301. type="application/x-vlc-plugin"
  302. pluginspage="http://www.videolan.org"
  303. name="vlc"
  304. width = "640px"
  305. height = "480px"
  306. target = "/test_mp4.php"
  307. />
  308. </object-->
  309. <video width="640px" height="480px" controls>
  310. <source src="/test_mp4.php" type='video/webm;codecs="vp8, vorbis"'/>
  311. </video>
  312. <?php
  313. };
  314. function UI_Begin2Section( $Width = '' ){
  315. if( $Width != '' ){
  316. ?><table width="100%" border=0 class="contentTable">
  317. <tr><td width="<?=$Width;?>"><?php
  318. } else {
  319. ?><table width="100%" border=0 class="contentTable">
  320. <tr><td ><?php
  321. };
  322. };
  323. function UI_SectionDelimiter( $Width='' ){
  324. if( $Width != '' ){
  325. ?></td><td width="<?=$Width;?>"><?php
  326. } else {
  327. ?></td><td><?php
  328. };
  329. };
  330. function UI_End2Section(){
  331. ?></td></tr>
  332. </table><?php
  333. };
  334. ?>