new cleanup and updates
[home-automation.git] / cameras.php
diff --git a/cameras.php b/cameras.php
new file mode 100644 (file)
index 0000000..51a80e7
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+include("config.php");
+if(isset($_GET['cam'])) {
+  foreach ($cameras as $id=>$camera) {
+    if ($_GET['cam'] == $id) {
+      echo "<img width='704px' height='480px' id='security' src='$camera[1]'>";
+      #echo "<img id='security' src='$camera[1]'>";
+    }
+  }
+} else {
+  $camera=$cameras[0];
+  echo "<img width='704px' height='480px' id='security' src='$camera[1]'>";
+}
+?>
+<table border=1>
+<tr style='background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#1E5799), color-stop(50%,#2989D8), color-stop(51%,#207cca), color-stop(100%,#7db9e8));background: -moz-linear-gradient(top, #
+1E5799 0%, #2989D8 50%, #207cca 51%, #7db9e8 100%);filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#1E5799', endColorstr='#7db9e8',GradientType=0 );'>
+<?php
+foreach ($cameras as $id=>$camera) {
+  echo "<td>";
+  ?>
+  <a href="javascript:clearTimeout(t);i=0;ajaxpage('<?php echo "cameras.php?cam=$id'"; ?>, 'contentarea');"  style="font-family: 'Times New Roman';font-size:16pt; color:#ffffff; filter:Glow(color=#ff0000, strength=12);"><?php echo $camera[0]; ?></a>
+  <?php
+  echo "</td>";
+}
+?>
+</tr>
+</table>