Public paste
axis
By: bla | Date: Feb 25 2010 09:10 | Format: HTML 4.01 strict | Expires: never | Size: 62.53 KB | Hits: 1707

  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.  
  19. <meta http-equiv="Expires" content="Tue, 12 May 1962 1:00:00 GMT">
  20. <meta http-equiv="Pragma" content="no-cache">
  21. <meta http-equiv="Cache-Control" content="no-cache">
  22. <meta http-equiv="Content-type" CONTENT="text/html; charset=iso-8859-1">
  23. <meta http-equiv="Content-language" CONTENT="en">
  24. <title>Live view  - AXIS M1031-W Network Camera</title>
  25.  
  26. <noscript>Your browser has JavaScript turned off.<br>For the user interface to work, you must enable JavaScript in your browser and reload/refresh this page.
  27.  
  28. <!-- GLOBAL JAVASCRIPTS -->
  29. <script language="JavaScript" type="text/javascript"><!--
  30. function launch(url) {
  31.  var w = 480, h = 340;
  32.  
  33.  if (document.all) {
  34.    /* the following is only available after onLoad */
  35.    w = document.body.clientWidth;
  36.    h = document.body.clientHeight;
  37.  }
  38.  else if (document.layers) {
  39.    w = window.innerWidth;
  40.    h = window.innerHeight;
  41.  }
  42.  
  43.  var popW = 475, popH = 590;
  44.  
  45.  var leftPos = (w-popW)/2, topPos = (h-popH)/2;
  46.  
  47.  self.name = "opener";
  48.  remote = open(url, 'helpWin', "resizable,scrollbars,status,width=" + popW + ",height="+popH+",left="+leftPos+",top="+topPos+"");
  49.  
  50.  //Fix for IE6 to solve problem with video stopping when opening help
  51.  try {
  52.    if ((typeof(useAMC) != "undefined")&&(useAMC == "yes") &&(navigator.appVersion.indexOf("MSIE 6") != -1) && (typeof(stopStartStream) == "function") && (typeof(imagepath) == "string"))
  53.      stopStartStream(imagepath);
  54.  } catch (e) {}
  55. }
  56.  
  57. function openPopUp(thePage, theName, theWidth, theHeight)
  58. {
  59.  theWidth = Number( theWidth ) + 10;
  60.  theHeight = Number( theHeight ) + 20;
  61.  
  62.  var someFeatures = 'scrollbars=yes,toolbar=0,location=no,directories=0,status=0,menubar=0,resizable=1,width=' + theWidth + ',height=' + theHeight;
  63.  var aPopUpWin = window.open(thePage, theName, someFeatures);
  64.  
  65.  if (navigator.appName == "Netscape") {
  66.    aPopUpWin.focus();
  67.  }
  68. }
  69.  
  70. function showStatus(msg)
  71. {
  72.  window.status = msg
  73.  return true
  74. }
  75. // -->
  76. </script><script language="JavaScript">
  77. <!--
  78. function CSS ()
  79. {
  80.  if ((navigator.appVersion.indexOf("Mac") != -1) && (navigator.appName.indexOf("Netscape") != -1)) {
  81.    document.write('<link rel="stylesheet" href="/css/mac_ns.css" type="text/css">');
  82.  
  83.  } else if ((navigator.appVersion.indexOf("Mac") != -1) && (navigator.appName.indexOf("Microsoft Internet Explorer") != -1)) {
  84.    document.write('<link rel="stylesheet" href="/css/mac_ie.css" type="text/css">');
  85.  
  86.  } else if ((navigator.appVersion.indexOf("Win") != -1) && (navigator.appName.indexOf("Netscape") != -1)) {
  87.    document.write('<link rel="stylesheet" href="/css/win_ns.css" type="text/css">');
  88.  
  89.  } else if ((navigator.appVersion.indexOf("Win") != -1) && (navigator.appName.indexOf("Microsoft Internet Explorer") != -1)) {
  90.    document.write('<link rel="stylesheet" href="/css/win_ie.css" type="text/css">');
  91.  
  92.  } else if (navigator.appName.indexOf("Netscape") != -1) {
  93.    // Unix or other system
  94.    document.write('<link rel="stylesheet" href="/css/win_ns.css" type="text/css">');
  95.  } else {        
  96.    document.write('<link rel="stylesheet" href="/css/other.css" type="text/css">');
  97.  }
  98.  
  99.  // Wrapper for old browsers which can't handle getElementById
  100.  if(!document.getElementById) {
  101.     document.getElementById = function(element)
  102.     {
  103.       return eval("document.all." + element);
  104.     }
  105.  }
  106. }
  107. // -->
  108. <script language="JavaScript" type="text/javascript"><!--
  109. CSS ();
  110. // -->
  111.  
  112. <script language="JavaScript" type="text/javascript">
  113. <!--
  114. function SubmitForm()
  115. {
  116.  document.WizardForm.submit();
  117. }
  118. // -->
  119.  
  120. <!-- END GLOBAL JAVASCRIPTS -->
  121.  
  122. <script type="text/javascript" src="/incl/slider.js"></script>
  123.  
  124. <SCRIPT LANGUAGE="JavaScript">
  125. <!--
  126.  
  127. if ((navigator.appName == "Microsoft Internet Explorer") &&
  128.    (navigator.platform != "MacPPC") &&
  129.    (navigator.platform != "Mac68k")) {
  130.  var browser = "IE"
  131. } else {
  132.  var browser = "Netscape"
  133. }
  134.  
  135. function drawBoxHeader(title)
  136. {
  137.  var args = drawBoxHeader.arguments;
  138.  var fill = (args.length >= 2 ? args[1] : false);
  139.  
  140.  document.write('' +
  141. '<td' + (fill ? ' width="100%"' : '') + '>' +
  142. '  <table width="100%" height="46" cellpadding=0 cellspacing=0 border=0>' +
  143. '    <tr>' +
  144. '      <td colspan=2 width=5 background="/pics/gray_corner_lt_5x50px.gif"><img src="/pics/blank.gif" width=5 height=5 border=0 alt=""></td>' +
  145. '      <td valign="top" align="center" width="100%" background="/pics/gray_t_5x50px.gif" height="5" class="funcText" nowrap>' + title + '</td>' +
  146. '      <td colspan=2 width=5  background="/pics/gray_corner_rt_5x50px.gif"><img src="/pics/blank.gif" width=5 height=5 border=0 alt=""></td>' +
  147. '    </tr>' +
  148. '    <tr>' +
  149. '      <td width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=5 alt=""></td>' +
  150. '      <td width=4><img src="/pics/blank.gif" width=4 height=5 alt=""></td>' +
  151. '      <td valign="middle" align="center" width="100%">' +
  152. '        <table cellpadding=0 cellspacing=0 border=0>' +
  153. '          <tr>');
  154. }
  155.  
  156. function drawBoxFooter()
  157. {
  158.  document.write('' +
  159. '          </tr>' +
  160. '        </table>' +
  161. '      </td>' +
  162. '      <td width=4><img src="/pics/blank.gif" width=4 height=5 alt=""></td>' +
  163. '      <td width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=5 alt=""></td>' +
  164. '    </tr>' +
  165. '    <tr>' +
  166. '      <td colspan=2 width=5 height=5><img src="/pics/line_corner_lb_5x5px.gif" width=5 height=5 border=0 alt=""></td>' +
  167. '      <td width="100%" height=5 background="/pics/line_b_100x5px.gif"><img src="/pics/blank.gif" width=1 height=5 alt=""></td>' +
  168. '      <td colspan=2 width=5 height=5><img src="/pics/line_corner_rb_5x5px.gif" width=5 height=5 border=0 alt=""></td>' +
  169. '    </tr>' +
  170. '  </table>' +
  171. '</td>');
  172. }
  173.  
  174. function drawBoxButton(pic, title)
  175. {
  176.  var args = drawBoxButton.arguments;
  177.  var url =      (args.length >= 3 ? args[2] : null);
  178.  var name =     (args.length >= 4 ? args[3] : null);
  179.  var pressed =  (args.length >= 5 ? args[4] : null);
  180.  var on_click = (args.length >= 6 ? args[5] : null);
  181.  var width =    (args.length >= 7 ? args[6] : 27);
  182.  var height =   (args.length >= 8 ? args[7] : 27);
  183.  
  184.  if (url) {
  185.    if (name) {
  186.      document.write('<td valign="middle" align="left">' +
  187.                     '<a href="' + url + '" id="' + name +'_link" target="Temp"' +
  188.                     (on_click ? ' onClick="' + on_click+ '"' : '') +
  189.                     ' onMouseDown="movepic('' + name + '', '' + pressed + '')"' +
  190.                     ' onMouseUp="movepic('' + name + '', '' + pic + '')"' +
  191.                     '>' +
  192.                     '<img name="' + name + '" src="' + pic + '" ' +
  193.                     'width=' + width + ' height=' + height + ' border=0 ' +
  194.                     (title ? ' title="' + title + '" alt="' + title + '"' : '') +
  195.                     '>' +
  196.                     '</a>' +
  197.                     '</td>');
  198.    } else {
  199.      document.write('<td valign="middle" align="left">' +
  200.                     '<a href="' + url + '" target="_self"' +
  201.                     (on_click ? ' onClick="' + on_click+ '"' : '') +
  202.                     '>' +
  203.                     '<img src="' + pic + '" ' +
  204.                     'width=' + width + ' height=' + height + ' border=0 ' +
  205.                     (title ? ' title="' + title + '" alt="' + title + '"' : '') +
  206.                     '>' +
  207.                     '</a>' +
  208.                     '</td>');
  209.    }
  210.  } else {
  211.    document.write('<td valign="middle" align="left">' +
  212.                   '<img src="' + pic + '" ' +
  213.                   'width=' + width + ' height=' + height + ' border=0' +
  214.                   (title ? ' title="' + title + '" alt="' + title + '"' : '') +
  215.                   '>' +
  216.                   '</td>');
  217.  }
  218. }
  219.  
  220. function drawBoxToggleButton(picActive, picActivePressed, titleActive, urlActive, nameActive, picInactive, picInactivePressed, titleInactive, urlInactive, nameInactive, initStatusActive)
  221. {
  222.  document.write('<td valign="middle" align="left">' +
  223.                 '<a href="' + urlActive + '" target="Temp"' +
  224.                 ' onMouseDown="movepic('' + nameActive + '', '' + picActivePressed + ''); movepic('' + nameInactive + '', '' + picInactive + '')"' +
  225.                 '>' +
  226.                 '<img name="' + nameActive + '" src="' + (initStatusActive ? picActivePressed : picActive) + '" ' +
  227.                 'width=27 height=27 border=0 ' +
  228.                 ' title="' + titleActive + '" alt="' + titleActive + '"' +
  229.                 '>' +
  230.                 '</a>' +
  231.                 '</td>');
  232.  document.write('<td valign="middle" align="left">' +
  233.                 '<a href="' + urlInactive + '" target="Temp"' +
  234.                 ' onMouseDown="movepic('' + nameActive + '', '' + picActive + ''); movepic('' + nameInactive + '', '' + picInactivePressed + '')"' +
  235.                 '>' +
  236.                 '<img name="' + nameInactive + '" src="' + (!initStatusActive ? picInactivePressed : picInactive) + '" ' +
  237.                 'width=27 height=27 border=0 ' +
  238.                 ' title="' + titleInactive + '" alt="' + titleInactive + '"' +
  239.                 '>' +
  240.                 '</a>' +
  241.                 '</td>');
  242. }
  243.  
  244. function drawBoxSpacer()
  245. {
  246.  document.write('<td width=5><img src="/pics/blank.gif" width=5 height=5 alt=""></td>');
  247. }
  248.  
  249. function changeaudioclip(clipselect)
  250. {
  251.  document.getElementById('audioclipbutton_link').href =
  252.    '/axis-cgi/playclip.cgi?clip=' + clipselect.value;
  253. }
  254.  
  255. function listVideoSources()
  256. {
  257.  var formInt = document.listFormInt
  258.  var formExt = document.listFormExt
  259.  var presetForm = document.listFormPreset;
  260.  var form = document.WizardForm
  261.  var currentPath = '/axis-media/media.amp?videocodec=h264';
  262.  var imageSource;
  263.  
  264.  if ((1 > 1) ||
  265.      ext_sources > 0
  266.     ) {
  267.    document.write('<select name="videoList" onChange="selectView()" >');
  268.  
  269.    if ((1 == 1) &&
  270.        ext_sources == 0
  271.       ) {
  272.      document.write('<option class="gray" value="no_change">&nbsp;----------------</option>');
  273.    } else {
  274.      for (i = 0; i < 1; i++) {
  275.        var camera_nice_nbr = i + 1;
  276.          imageSource = "/axis-media/media.amp?videocodec=h264";
  277.        document.write('<option value="' + imageSource + '"');
  278.        if (imageSource == currentPath ||
  279.            '/jpg/image.jpg' == currentPath) {
  280.          document.write(' selected');
  281.        }
  282.  
  283.        document.write('>' + formInt['root_ImageSource_I' + i + '_Name'].value + '</option>');
  284.      }
  285.    }
  286. var viewAppletIE = "no";
  287. var viewAppletOther = "no";
  288. // Don't show external sources while using Java applet as Default Viewer. An unsigned applet doesn't have permission to access remote hosts.
  289. if (((browser == "IE") && (viewAppletIE == "no")) || ((browser != "IE") && (viewAppletOther == "no"))) {
  290.    if (formExt.elements.length > 0) {
  291.      for (i = 0; i < formExt.elements.length; i += 3) {
  292.        var aTempString = formExt.elements[i].name
  293.        var videoNr = aTempString.substring(20, aTempString.lastIndexOf('_'))
  294.        var external = formExt['root_ExternalVideo_E' + videoNr + '_ImagePath'].value;
  295.  
  296.          document.write('<option value="' + external + '"');
  297.          if (formExt['root_ExternalVideo_E' + videoNr + '_ImagePath'].value == currentPath)
  298.            document.write(' selected');
  299.          document.write('>' + formExt['root_ExternalVideo_E' + videoNr + '_Name'].value + '</option>');
  300.      }
  301.    }
  302. }
  303.    document.write('</select>');
  304.    document.write("<input type="button" value="Go" width="40" onClick="JavaScript:selectView()">");
  305. //} else {
  306. //  document.write(formInt.root_ImageSource_I0_Name.value);
  307.  }
  308. }
  309.  
  310. function zoom(size)
  311. {
  312.  var url = document.URL;
  313.  
  314.  if (url.indexOf("?") == -1) {
  315.    url += "?size=" + size
  316.  } else if (url.indexOf("size=") == -1) {
  317.    url += "&size=" + size
  318.  } else {
  319.    var searchStr = "size=1"
  320.    var replaceStr = "size=" + size
  321.    var re = new RegExp(searchStr , "g")
  322.    url = url.replace(re, replaceStr)
  323.  }
  324.  
  325.  document.location = url;
  326. }
  327.  
  328. var aNewImagePath;
  329.  
  330. function reloadPage()
  331. {
  332.  document.location = aNewImagePath;
  333. }
  334.  
  335. function selectView()
  336. {
  337.  var form = document.WizardForm;
  338.  var source = form.videoList.options[form.videoList.selectedIndex].value;
  339.  var params = source.split('&');
  340.  var newCamera = null;
  341.  var presetName = null;
  342.  
  343.  if ((params[1] != null) && ("no" == "no")) {
  344.    if (source.lastIndexOf("camera=") != -1) {
  345.      if (source.lastIndexOf("&") > source.lastIndexOf("camera="))
  346.        newCamera = source.substring(source.lastIndexOf("camera=")+7, source.lastIndexOf("&"))
  347.      else
  348.        newCamera = source.substr(source.lastIndexOf("camera=")+7)
  349.    }
  350.    if (source.lastIndexOf("gotopresetname=") != -1) {
  351.      if (source.lastIndexOf("&") > source.lastIndexOf("gotopresetname="))
  352.        presetName = source.substring(source.lastIndexOf("gotopresetname=")+15, source.lastIndexOf("&")-1)
  353.      else
  354.        presetName = source.substr(source.lastIndexOf("gotopresetname=")+15)
  355.    }
  356.    source = params[0];
  357.    if (source.indexOf("?") != -1)
  358.      source = source.substring(0, source.indexOf("?"))
  359.  } else if (source == "no_change") {
  360.    return;
  361.  }
  362.  if (presetName != null) gotopresetname = presetName;
  363.  
  364.  changeView(source, newCamera, presetName);
  365. }
  366.  
  367. function changeView(imagePath)
  368. {
  369.  var args = changeView.arguments;
  370.  var newCamera  = (args.length >= 2 ? args[1] : null);
  371.  var presetName = (args.length >= 3 ? args[2] : null);
  372.  var newSize    = (args.length >= 4 ? args[3] : null);
  373.  var other      = (args.length >= 5 ? args[4] : null);
  374.  
  375.  // Go to correct preset when coming from an external video source
  376.  if ((presetName == null || presetName == "") && (imagePath.indexOf("gotopresetname=") != -1)) {
  377.    presetName = imagePath.slice(imagePath.indexOf("gotopresetname=") + 15)
  378.    if (presetName.indexOf("&") != -1)
  379.      presetName = presetName.substring(0, presetName.indexOf("&"))
  380.  }
  381.  if ((newCamera == null || newCamera == "") && (imagePath.indexOf("camera=") != -1)) {
  382.    newCamera = imagePath.slice(imagePath.indexOf("camera=") + 7)
  383.    if (newCamera.indexOf("&") != -1)
  384.      newCamera = newCamera.substring(0, newCamera.indexOf("&"))
  385.  }
  386.  
  387.  var reload = false;
  388.  // the whole Live View design is built on page reload >-(
  389.  // must reload initial sequence mode view to toggle buttons etc
  390.  reload = (other != null && other.search("seq=yes"));
  391.  var delay = 0;
  392.  
  393.  reload |= (imagePath != '/axis-media/media.amp?videocodec=h264');
  394.  if (reload) {
  395.    var size = newSize;
  396.  
  397.    // avoid request being suspended due to page reload
  398.    delay = 100;
  399.  
  400.    if (size == null) {
  401.      size = 1;
  402.    }
  403.    if (size != null) {
  404.      size = '&size=' + size;
  405.    }
  406.    aNewImagePath = '/view/view.shtml?id=22&imagePath=' + escape(imagePath) + size;
  407.    if (other != null)
  408.      aNewImagePath += other;
  409.    setTimeout("reloadPage()", delay);
  410.  }
  411. }
  412.  
  413. var seqNext = null;
  414.  
  415. function doSequence(size) {
  416.  var formSeq = document.listFormSeq;
  417.  var formExt = document.listFormExt;
  418.  var presetForm = document.listFormPreset;
  419.  var seqSources = new Array();
  420.  var seqNumbers = new Array();
  421.  var seqTimes = new Array();
  422.  var cameraNbr;
  423.  var presetName = null;
  424.  var imagePath;
  425.  var next;
  426.  
  427.  for (var i = 0; i < formSeq['root_Sequence_S0_NbrOfSources'].value; i++) {
  428.    seqSources[i] = formSeq['root_Sequence_S0_Source_S' + i + '_Type'].value;
  429.    seqNumbers[i] = formSeq['root_Sequence_S0_Source_S' + i + '_Number'].value;
  430.    seqTimes[i] = formSeq['root_Sequence_S0_Source_S' + i + '_Time'].value;
  431.  }
  432.  
  433.  if (seqNext != null) {
  434.    next = seqNext;
  435.  } else {
  436.    next = 0;
  437.  }
  438.  
  439.  imagePath = "";
  440.  if (seqSources[next] == 'Ext') {
  441.    imagePath = formExt['root_ExternalVideo_E' + seqNumbers[next] + '_ImagePath'].value;
  442.  }
  443.  else if (seqSources[next] == 'Quad') {
  444.    cameraNbr = 'quad';
  445.  } else {
  446.    cameraNbr = parseInt(seqNumbers[next]) + 1;
  447.  }
  448.  
  449.  if (imagePath == "") {
  450.      imagePath = '/axis-media/media.amp?videocodec=h264&camera=' + cameraNbr;
  451.  }
  452.  
  453.  var nextNext;
  454.  if (formSeq['root_Sequence_S0_RandomEnabled'].value == "yes")
  455.    nextNext = Math.floor(Math.random() * formSeq['root_Sequence_S0_NbrOfSources'].value);
  456.  else
  457.    nextNext = next + 1;
  458.  if (nextNext >= formSeq['root_Sequence_S0_NbrOfSources'].value)
  459.    nextNext = 0;
  460.  
  461.  seqNext = nextNext;
  462.    changeView(imagePath, cameraNbr, presetName, size, '&seq=yes&next=' + nextNext + '&sequencetime=' + seqTimes[next]);
  463.  
  464.    t1 = setTimeout("doSequence(" + size + ")", 1000 * seqTimes[next]);
  465. }
  466.  
  467.  
  468. function snapshot(imagepath)
  469. {
  470.  var no = document.WizardForm.amount.value++
  471.  var picturepath;
  472.  var protEnd = imagepath.indexOf("://");
  473.  var camIndex = imagepath.indexOf("camera=");
  474.  
  475.  if (imagepath.charAt(0) == '/' && protEnd < 0) {
  476.    if (camIndex >= 0) {
  477.      var secondEt = imagepath.indexOf('&', camIndex);
  478.      var camnbr = imagepath.substring(camIndex + 7, (secondEt >= 0 ? secondEt : imagepath.length));
  479.    } else {
  480.      var firstSlash = imagepath.indexOf('/', 1);
  481.      var secondSlash = imagepath.indexOf('/', firstSlash);
  482.      var camnbr = imagepath.substring(firstSlash, (secondSlash >= 0 ? secondSlash : imagepath.length));
  483.    }
  484.    picturepath = "/jpg/" + camnbr + "/image.jpg";
  485.  } else {
  486.    if (imagepath.indexOf("h264") >= 0 || imagepath.indexOf("mpeg4") >= 0) {
  487.      var prot = document.location.protocol;
  488.      var imageHost = imagepath.substring(protEnd + 3, imagepath.indexOf('/', protEnd+3));
  489.      var secondEt = imagepath.indexOf('&', camIndex);
  490.      var camnbr = imagepath.substring(camIndex + 7, (secondEt >= 0 ? secondEt : imagepath.length));
  491.      picturepath = prot + "//" + imageHost + "/jpg/" + camnbr + "/image.jpg";
  492.    } else {
  493.      picturepath = imagepath.replace(/video/, "image").replace(/mjpg/g, "jpg");
  494.    }
  495.  }
  496.  var page = 'snapshot.shtml?picturepath=' + picturepath
  497.  var time = new Date()
  498.  var timestamp = time.getTime()
  499.  
  500.  page += '&timestamp=' + timestamp + '&width=' + 640
  501.  openPopUp(page, 'Take_snapshot' + [no] + '', 640 + 45, 480 + 75 )
  502. }
  503. function movepic(img_name, img_src)
  504. {
  505.  document[img_name].src = img_src;
  506. }
  507.  
  508. function auto(Path)
  509. {
  510.  parent.frames[1].location = Path
  511. }
  512.  
  513. function AbsoluteOrRelative(form)
  514. {
  515.  var url = document.URL;
  516.  if (form.AbsOrRel.selectedIndex == 0)
  517.    var relative = "no";
  518.  else
  519.    var relative = "yes_no_cross";
  520.  if (url.indexOf("?") == -1) {
  521.    url += "?relative=" + relative;
  522.  } else if (url.indexOf("relative=") == -1) {
  523.    url += "&relative=" + relative;
  524.  } else {
  525.    var searchStr = "relative=";
  526.    var replaceStr = "relative=" + relative;
  527.    var re = new RegExp(searchStr , "g");
  528.    url = url.replace(re, replaceStr);
  529.  }
  530.  document.location = url;
  531. }  
  532. var stillImagePath;
  533. var use_activex = 0;
  534. var use_java = 0;
  535. var use_spush = 0;
  536. var use_flash = 0;
  537. var use_still = 0;
  538. var use_quicktime = 0;
  539.  
  540. function video(imagepath)
  541. {
  542.  var resolution = 0
  543.  var width = 0
  544.  var height = 0
  545.  
  546.  if (imagepath.indexOf("resolution=") != -1) {
  547.    var resStart = imagepath.indexOf("resolution=")
  548.    var resStop = imagepath.indexOf("&", resStart)
  549.    if (resStop == -1) resStop = imagepath.length
  550.    resolution = imagepath.substring(resStart + 11, resStop);
  551.    if (resolution.indexOf('x') != -1) {
  552.      width = parseInt(resolution.substring(0, resolution.indexOf('x')));
  553.      height = parseInt(resolution.slice((resolution.indexOf('x') + 1)));
  554.    }
  555.  }
  556.  
  557.  if (!(width > 0 && height > 0)) {
  558.    if ((imagepath.indexOf("mpeg4") != -1) || (imagepath.indexOf("h264") != -1)) {
  559.      width = parseInt("640");
  560.      height = parseInt("480");
  561.      resolution = width + 'x' + height;
  562.    } else {
  563.      width = parseInt("640");
  564.      height = parseInt("480");
  565.      resolution = width + 'x' + height;
  566.    }
  567.  }
  568.  
  569.  if ('1' != '1') {
  570.    var strSize = '1';
  571.    var sizeNum = 0;
  572.    //floating number try to parse it
  573.    if( strSize.indexOf('.') != -1  )
  574.    {
  575.      sizeNum = parseFloat( strSize );
  576.      //might be the wrong decimal separation
  577.      if( sizeNum == 0 || isNaN( sizeNum ) )
  578.      {
  579.        strSize = strSize.replace( ".", "," );
  580.        sizeNum = parseFloat( strSize );
  581.      }
  582.    }
  583.    else if( strSize.indexOf(',') != -1  )
  584.    {
  585.      sizeNum = parseFloat( strSize );
  586.      //might be the wrong decimal separation
  587.      if( sizeNum == 0 || isNaN( sizeNum ) )
  588.      {
  589.        strSize = strSize.replace( ",", "." );
  590.        sizeNum = parseFloat( strSize );
  591.      }
  592.    }
  593.    else
  594.    {
  595.      sizeNum = parseInt( strSize );
  596.    }
  597.    width = width * sizeNum;
  598.    height = height * sizeNum;
  599.  }
  600.  
  601.  
  602.  var width_height = 'width="' + width + '" height="' + height + '"';
  603.  var viewer = "still";
  604.  
  605.  if ((navigator.appName == "Microsoft Internet Explorer") && (navigator.platform != "MacPPC") && (navigator.platform != "Mac68k")) {
  606.    viewer = "activex";
  607.  } else {
  608.    viewer = "spush";
  609.  }
  610.  
  611.  if (viewer.indexOf("activex") != -1) {
  612.    use_activex = 1;
  613.  }
  614.  if (viewer.indexOf("spush") != -1) {
  615.    use_spush = 1;
  616.  }
  617.  if (viewer.indexOf("flash") != -1) {
  618.    use_flash = 1;
  619.  }
  620.  if (viewer.indexOf("quicktime") != -1) {
  621.    use_quicktime = 1;
  622.  }
  623.  if ((imagepath.indexOf("videocodec=mpeg4") != -1) || (imagepath.indexOf("videocodec=h264") != -1)) {
  624.    if ((navigator.appName == "Microsoft Internet Explorer") && (navigator.platform != "MacPPC") && (navigator.platform != "Mac68k")) {
  625.        use_quicktime = 0;
  626.        use_activex = 1;
  627.    } else {
  628.      use_quicktime = 1;
  629.      use_spush = 0;
  630.      use_still = 0;
  631.    }
  632.  } else {
  633.    if ((navigator.appName == "Microsoft Internet Explorer") && (navigator.platform != "MacPPC") && (navigator.platform != "Mac68k")) {
  634.        use_quicktime = 0;
  635.        use_activex = 1;
  636.    } else {
  637.      use_quicktime = 0;
  638.      use_spush = 1;
  639.      use_still = 0;
  640.    }
  641.  }
  642.  if (viewer.indexOf("java") != -1) {
  643.    if ((imagepath.indexOf("mpeg4") == -1) && (imagepath.indexOf("h264") == -1)) {
  644.      use_java = 1;
  645.      use_activex = 0;
  646.      use_spush = 0;
  647.      use_flash = 0;
  648.      use_still = 0;
  649.      use_quicktime = 0;
  650.    }
  651.  }
  652.  if ((viewer.indexOf("still") != -1) || !(use_activex || use_spush || use_flash || use_java || use_quicktime)) {
  653.    if ((imagepath.indexOf("mpeg4") == -1) && (imagepath.indexOf("h264") == -1)) {
  654.      use_still = 1;
  655.      use_quicktime = 0;
  656.      use_spush = 0;
  657.      use_activex = 0;
  658.    } else {
  659.      if ((navigator.appName == "Microsoft Internet Explorer") && (navigator.platform != "MacPPC") && (navigator.platform != "Mac68k")) {
  660.        use_activex = 1;
  661.      } else {
  662.        use_quicktime = 1;
  663.      }
  664.    }
  665.  }
  666.  var agent = navigator.userAgent.toLowerCase();
  667.  if (agent.indexOf("applewebkit/") != -1) {
  668.    var pos = agent.indexOf("applewebkit/") + 12
  669.    var webKitVersion = parseInt(agent.substring(pos, agent.indexOf(" ", pos)))
  670.    if ((use_spush) && (webKitVersion < 416)) {
  671.      use_java = 1;
  672.      use_spush = 0;
  673.    }
  674.  }
  675.  if (use_activex) {
  676.    height = height + 54
  677.    var notAuthorizedText = "The installation of the MPEG-4 Decoder has been disabled. Contact the Administrator of this AXIS M1031-W Network Camera.";
  678.    var notAuthorizedH264Text = "The installation of the H.264 Decoder has been disabled. Contact the Administrator of this AXIS M1031-W Network Camera.";
  679.    var authorizedText = "Click here to install or upgrade the MPEG-4 Decoder.";
  680.    var authorizedH264Text = "Click here to install or upgrade the H.264 Decoder.";
  681.    var installDecoderText1 = "<b>MPEG-4 Decoder</b>, which enables streaming video in Microsoft Internet Explorer, has not been installed or could not be registered on this computer.";
  682.    var installDecoderH264Text1 = "<b>The H.264 Decoder</b>, which enables streaming video in Microsoft Internet Explorer, has not been installed or could not be registered on this computer.";
  683.    var installDecoderText2 = "To <a href="javascript:launch('/incl/license.shtml')">install or upgrade</a> the MPEG-4 Decoder, you must have Administration rights on this computer and you must answer Yes <br>when asked if you wish to allow the installation. AXIS M1031-W Network Camera can also be configured to show still images.";
  684.    var installDecoderH264Text2 = "To <a href="javascript:launch('/incl/license_h264.shtml')">install or upgrade</a> the H.264 Decoder, you must have Administration rights on this computer and you must answer Yes <br>when asked if you wish to allow the installation. AXIS M1031-W Network Camera can also be configured to show still images.";
  685.    var notAuthorizedAacText = "The installation of the AAC Decoder has been disabled. Contact the Administrator of this AXIS M1031-W Network Camera.";
  686.    var authorizedAacText = "Click here to install or upgrade the AAC Decoder.";
  687.    var installAacDecoderText1 = "<b>AAC Decoder</b>, which enables streaming AAC audio in Microsoft Internet Explorer, has not been installed or could not be registered on this computer.";
  688.    var installAacDecoderText2 = "To <a href="javascript:launch('/incl/aac_license.shtml')">install or upgrade</a> the AAC Decoder, you must have Administration rights on this computer and you must answer Yes <br>when asked if you wish to allow the installation.";
  689.  
  690.    var installText1 = "which enables streaming";
  691.    var videoText = "video";
  692.    var audioText = "audio";
  693.    var installText2 = "in Microsoft Internet Explorer, has not been installed or could not be registered on this computer.";
  694.    var installText3 = "To install or upgrade the";
  695.    var installText4 = ", you must have Administration rights on this computer and you must answer Yes <br>when asked if you wish to allow the installation. AXIS M1031-W Network Camera can also be configured to show still images.";
  696.    DrawAMC("AXIS M1031-W", "AXIS Media Control", height, width, imagepath, "DE625294-70E6-45ED-B895-CFFA13AEB044", "AMC.cab", "5,4,17,13", "yes", "", "", "1", "", "", "", "", "yes", "554", "no", installText1, videoText, installText2, installText3, installText4, "0", "", "");
  697.  
  698.    if (imagepath.indexOf("mpeg4") != -1) {
  699.      InstallDecoder("AXIS M1031-W", "MPEG-4 Decoder", "c32fe9f1-a857-48b0-b7bf-065b5792f28d", "NotFound.cab", "2,1,3,0", "yes", notAuthorizedText, authorizedText, installDecoderText1, installDecoderText2);
  700.      InstallFilter("AXIS M1031-W", "MPEG RTP Reader", "67B1A88A-B5D2-48B1-BF93-EB74D6FCB077", "2,3,9,6", "AMC.cab", installText1, videoText, installText2, installText3, installText4);
  701.      InstallFilter("AXIS M1031-W", "Image Notify Component", "0173EEF5-1FDE-479C-9F24-34C3CB0B3243", "1,2,1,0", "AMC.cab", installText1, videoText, installText2, installText3, installText4);
  702.    }
  703.    if (imagepath.indexOf("h264") != -1) {
  704.      InstallDecoder("AXIS M1031-W", "H.264 Decoder", "7340F0E4-AEDA-47C6-8971-9DB314030BD7", "NotFound.cab", "2,1,12,0", "yes", notAuthorizedH264Text, authorizedH264Text, installDecoderH264Text1, installDecoderH264Text2);
  705.      InstallFilter("AXIS M1031-W", "MPEG RTP Reader", "67B1A88A-B5D2-48B1-BF93-EB74D6FCB077", "2,3,9,6", "AMC.cab", installText1, videoText, installText2, installText3, installText4);
  706.      InstallFilter("AXIS M1031-W", "Image Notify Component", "0173EEF5-1FDE-479C-9F24-34C3CB0B3243", "1,2,1,0", "AMC.cab", installText1, videoText, installText2, installText3, installText4);
  707.    }
  708.  
  709.          InstallDecoder("AXIS M1031-W", "AAC Decoder", "ba7a56eb-d1b9-443b-96e9-086532a378f1", "NotFound.cab", "2,0,7,0", "yes", notAuthorizedAacText, authorizedAacText, installAacDecoderText1, installAacDecoderText2);
  710.      InstallFilter("AXIS M1031-W", "AudioComponent", "C111A91F-D4EC-4D22-8D27-C3BCB0389F43", "2,1,12,9", "AMC.cab", installText1, audioText, installText2, installText3, installText4);
  711.  
  712.    document.write("<br>");
  713.  }
  714.  
  715.  if (use_spush) {
  716.    document.write('<table cellspacing=0 cellpadding=0 border=0><tr><td colspan="3" align="center">');
  717.      var output = '<img id="stream" SRC="' + imagepath + '" ' + width_height;
  718.      var view_NoImageTxt = "If no image is displayed, there might be too many viewers, or the browser configuration may have to be changed. See help for detailed instructions on how to do this."
  719.      output += ' border=0 ALT="' + view_NoImageTxt + '">';
  720.    output += '<br>';
  721.    document.write(output);
  722.    if (document.getElementById("stream"))
  723.      var fullImagePath = document.getElementById("stream").src
  724.    else
  725.      var fullImagePath = "";
  726.    stillImagePath = "/jpg/1/image.jpg"
  727.    if (imagepath.indexOf("/axis-cgi/mjpg/video.cgi") != -1) {
  728.      var searchStr = "/axis-cgi/mjpg/video.cgi"
  729.      var replaceStr = "/jpg/1/image.jpg"
  730.      var re = new RegExp(searchStr , "g")
  731.      stillImagePath = imagepath.replace(re, replaceStr)
  732.    }
  733.  
  734.    document.write('</td></tr>');
  735.  
  736.  
  737.  document.write('<tr><td colspan="3" align="center" style="white-space:nowrap">' );
  738.  
  739.  
  740.  document.write('<div class="cornerVideoBox"><div class="content">');
  741.  document.write('<table cellspacing=0 border=0 width="100%" id="videoItems" class="shownItems">');
  742.  document.write('<tr height="32">');
  743.  document.write("<td align="right" width="40"><a id="stopBtn" href="javascript:void(0)" onclick="stopStartStream('" + stillImagePath + "')"><img src="/pics/stop_blue_button_27x27px.gif" width="27" height="27" alt="Stop stream" title="Stop stream" border="0" onmouseover="javascript:btnShiftCls( this, true )" onmouseout="javascript:btnShiftCls( this, false )" /></a>");
  744.  document.write("<a id="playBtn" style="display:none;" href="javascript:void(0)" onclick="stopStartStream('" + fullImagePath + "')"><img src="/pics/play_blue_button_27x27px.gif" width="27" height="27" alt="Start stream" title="Start stream" border="0" onmouseover="javascript:btnShiftCls( this, true )" onmouseout="javascript:btnShiftCls( this, false )" /></a></td>");
  745.  document.write("<td>&nbsp;</td></tr></table>");
  746.  
  747.  
  748.  document.write('</div><div class="footerLeft"><div class="footerRight"></div></div></div>');
  749.  
  750.  
  751.  
  752.  document.write('</td></tr></table>');
  753.  }
  754.  
  755.  if (use_quicktime) {
  756.    var DisplayWidth = width;
  757.    var DisplayHeight = height  + 16;
  758.    var rtspPort = "554";
  759.    if (imagepath.indexOf("://") == -1) {
  760.      if (location.hostname.split(":").length > 1) {
  761.        //IPv6
  762.        var MediaURL = "rtsp://[" + location.hostname + "]:" + rtspPort + imagepath
  763.      } else {
  764.        //IPv4
  765.        var MediaURL = "rtsp://" + location.hostname + ":" + rtspPort + imagepath
  766.      }
  767.    } else {
  768.      var MediaURL = imagepath
  769.    }
  770.  
  771.    var output = "";
  772.    output  = '<OBJECT CLASSID="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width=' + DisplayWidth + ' height=' + DisplayHeight + ' CODEBASE="http://www.apple.com/qtactivex/qtplugin.cab">';
  773.    output += '<param name="src" value="/view/AxisMoviePoster.mov">';
  774.    output += '<param name="autoplay" value="true">';
  775.    output += '<param name="controller" value="true">';
  776.    output += '<param name="qtsrc" value="' + MediaURL + '">';
  777.    output += '<embed src="/view/AxisMoviePoster.mov" width=' + DisplayWidth + ' height=' + DisplayHeight + ' qtsrc="' + MediaURL + '" autoplay="true" controller="true" target="myself" PLUGINSPAGE="http://www.apple.com/quicktime/download/"></embed>';
  778.    output += '</OBJECT>';
  779.    document.write(output);
  780.  }
  781.  
  782.  if (use_flash) {
  783.    var view_NeedFlashPluginTxt = "You need a Shockwave Flash plugin, get it from:"
  784.    document.write('<EMBED src="/axis-cgi/mjpg/video.swf?resolution=' + resolution +'&camera=1" ' +
  785.    'quality=high bgcolor=#000000 ' + width_height +
  786.    ' TYPE="application/x-shockwave-flash" swLiveConnect=TRUE' +
  787.    ' PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">' +
  788.    '</EMBED>' +
  789.    '<NOEMBED>' + view_NeedFlashPluginTxt +
  790.    '<a href="http://www.macromedia.com/shockwave/download/">Macromedia</a>.' +
  791.    '</NOEMBED><br>');
  792.  }
  793.  
  794.  if (use_java) {
  795.    var playerWidth = width;
  796.    var playerHeight = height + 105;
  797.    if (playerWidth < 300)
  798.      playerWidth = 300;
  799.  
  800.    if (imagepath.indexOf("http") != -1) {
  801.      var addrEnd = imagepath.indexOf("/", 8);
  802.      var addr = imagepath;
  803.    } else {
  804.      var addr = "";
  805.    }
  806.  
  807.    document.write('<OBJECT name="AMA" codeBase="/java/ama" archive="ama.jar" code="ama.MediaApplet" codetype="application/x-java-applet;version=1.4" type="application/x-java-applet;version=1.4" width="' + playerWidth + '" height="' + playerHeight + '">');
  808.    document.write('<PARAM NAME="name" VALUE="AMA">');
  809.    document.write('<PARAM NAME="codebase" VALUE="/java/ama">');
  810.    document.write('<PARAM NAME="archive" VALUE="ama.jar">');
  811.    document.write('<PARAM NAME="code" VALUE="ama.MediaApplet">');
  812.    document.write('<PARAM NAME="codetype" VALUE="application/x-java-applet;version=1.4">');
  813.    document.write('<PARAM NAME="type" VALUE="application/x-java-applet;version=1.4">');
  814.    document.write('<PARAM NAME="mayscript" VALUE="false">');
  815.    document.write('<PARAM NAME="ama_cgi-path" VALUE="axis-cgi">');
  816.    document.write('<PARAM NAME="cache_archive" VALUE="ama.jar">');
  817.    document.write('<PARAM NAME="cache_version" VALUE="1.1.0.3">');
  818.    document.write('<PARAM NAME="ama_plugins" VALUE="">');
  819.  var img_opts = "";
  820.  if (imagepath.indexOf("?") > 0) {
  821.    img_opts += imagepath.substring(imagepath.indexOf("?"));
  822.    imagepath = imagepath.substring(0, imagepath.indexOf("?"));
  823.  }
  824.  if (img_opts.indexOf("camera=") == -1)
  825.    img_opts += (img_opts.indexOf("?") >= 0 ? "&" : "?") + "camera=1";
  826.  
  827.    if (img_opts.indexOf("rotation=") == -1)
  828.      img_opts += (img_opts.indexOf("?") >= 0 ? "&" : "?") + "rotation=0";
  829.  document.write('<PARAM NAME="ama_url" VALUE="' + imagepath + img_opts + '">');
  830.    document.write("Your browser does not support Java")
  831.    document.write('</OBJECT><br>');
  832.  }
  833.  
  834.  if (use_still) {
  835.    var picturepath;
  836.    var tmpAddress = imagepath.match(///(.+?)//g);
  837.  
  838.    if (tmpAddress == null)
  839.      tmpAddress = imagepath.match(/(.+?)//g);
  840.  
  841.    if (imagepath.charAt(0) == '/' || tmpAddress == null)
  842.      picturepath = "/jpg/1/image.jpg";
  843.    else
  844.      picturepath = document.location.protocol + "//" + tmpAddress + "/jpg/1/image.jpg";
  845.  
  846.    document.write('<img SRC="' + picturepath + '" border=0 ' + width_height +'><br>');
  847.  }
  848. }
  849.  
  850. function stopStartStream(path)
  851. {
  852.  try {
  853.    var orgPath = path;
  854.    theDate = new Date();
  855.    if (path.indexOf("?") != -1)
  856.      path += "&"
  857.    else
  858.      path += "?"
  859.    path += "timestamp=" + theDate.getTime()
  860.    if (use_spush) {
  861.      stopStartBtnShift( orgPath );
  862.      document.getElementById("stream").src = path;
  863.    } else if (use_activex) {
  864.      document.Player.MediaURL = path;
  865.    }
  866.  }
  867.  catch(e) {}
  868. }
  869.  
  870.  
  871. function stopStartBtnShift( orgPath )
  872. {
  873.  if( orgPath == stillImagePath )
  874.  {
  875.    document.getElementById("stopBtn").style.display = 'none';
  876.    document.getElementById("playBtn").style.display = 'inline';
  877.  }
  878.  else
  879.  {
  880.    document.getElementById("stopBtn").style.display = 'inline';
  881.    document.getElementById("playBtn").style.display = 'none';
  882.  }
  883.  
  884. }
  885.  
  886. function btnShiftCls( btnEl, over )
  887. {
  888.  if( btnEl ){
  889.    btnEl.className = ((over)?'hover':'');
  890.  }
  891. }
  892.  
  893.  
  894. function goto_camera(cam)
  895. {
  896.  cam += ''; // cam value needs to be a string, not an integer, for cam.length to work.
  897.  cam = '';
  898.  
  899.  var imagePath;
  900.  newVideoFormatCam(cam);
  901. }
  902.  
  903. function getStreamProfileNbr()
  904. {
  905.  return getProfileGrp(document.profileForm,"");
  906. }
  907.  
  908. function getStreamProfileName()
  909. {
  910.  return document.profileForm["root_StreamProfile_S" + getStreamProfileNbr() + "_Name"].value
  911. }
  912.  
  913. // -->
  914. </SCRIPT><!-- $camnbr = quad --><!-- $external = no -->
  915.  
  916. <SCRIPT SRC="/incl/activeX.js?id=22"></SCRIPT>
  917. </head>
  918.   <body class="bodyBg" topmargin="0" leftmargin="15" marginwidth="0" marginheight="0" onLoad="DrawTB('yes', '/axis-media/media.amp?videocodec=h264', '1', '0', 'no', '', getStreamProfileNbr());initSliders();" onResize="initSliders();">
  919.  
  920. <SCRIPT LANGUAGE="JavaScript">
  921. <!--
  922.  var t1;
  923.  var seqOn = "no";
  924.  
  925. function sequence()
  926. {
  927.  var size;
  928.  if (seqOn == 'no') {
  929.    seqOn = 'yes';
  930.    size = 1;
  931.    doSequence(size);
  932.  } else {
  933.    clearTimeout(t1);
  934.    seqOn = 'no';
  935.    link = document.URL;
  936.    if (link.indexOf('seq=yes' != -1)) {
  937.      var regexp = /seq=yes&/;
  938.      link = link.replace(regexp, "");
  939.    }
  940.    document.location = link;
  941.  }
  942.  return;
  943. }
  944.  
  945. // -->
  946. </SCRIPT><!-- $ptzpresets = "yes" -->
  947.  
  948. <form name="profileForm"><input type="hidden" name="root_StreamProfile_MaxGroups" value="20" ><input type="hidden" name="root_StreamProfile_S0_Name" value="Quality" ><input type="hidden" name="root_StreamProfile_S0_Description" value="Best image quality and full frame rate." ><input type="hidden" name="root_StreamProfile_S0_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=20&amp;fps=0&amp;videokeyframeinterval=8&amp;videobitrate=0" ><input type="hidden" name="root_StreamProfile_S0_Default_Name" value="Quality" ><input type="hidden" name="root_StreamProfile_S0_Default_Description" value="Best image quality and full frame rate." ><input type="hidden" name="root_StreamProfile_S0_Default_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=20&amp;fps=0&amp;videokeyframeinterval=8&amp;videobitrate=0" ><input type="hidden" name="root_StreamProfile_S1_Name" value="Balanced" ><input type="hidden" name="root_StreamProfile_S1_Description" value="Medium image quality and frame rate." ><input type="hidden" name="root_StreamProfile_S1_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=30&amp;fps=15&amp;videokeyframeinterval=15&amp;videobitrate=0" ><input type="hidden" name="root_StreamProfile_S1_Default_Name" value="Balanced" ><input type="hidden" name="root_StreamProfile_S1_Default_Description" value="Medium image quality and frame rate." ><input type="hidden" name="root_StreamProfile_S1_Default_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=30&amp;fps=15&amp;videokeyframeinterval=15&amp;videobitrate=0" ><input type="hidden" name="root_StreamProfile_S2_Name" value="Bandwidth" ><input type="hidden" name="root_StreamProfile_S2_Description" value="Low bandwidth with medium image quality." ><input type="hidden" name="root_StreamProfile_S2_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=50&amp;fps=15&amp;videokeyframeinterval=30&amp;videobitrate=250&amp;videomaxbitrate=1000&amp;videobitratepriority=framerate" ><input type="hidden" name="root_StreamProfile_S2_Default_Name" value="Bandwidth" ><input type="hidden" name="root_StreamProfile_S2_Default_Description" value="Low bandwidth with medium image quality." ><input type="hidden" name="root_StreamProfile_S2_Default_Parameters" value="videocodec=h264&amp;resolution=640x480&amp;compression=50&amp;fps=15&amp;videokeyframeinterval=30&amp;videobitrate=250&amp;videomaxbitrate=1000&amp;videobitratepriority=framerate" ><input type="hidden" name="root_StreamProfile_S3_Name" value="Mobile" ><input type="hidden" name="root_StreamProfile_S3_Description" value="Mobile device settings." ><input type="hidden" name="root_StreamProfile_S3_Parameters" value="videocodec=h264&amp;resolution=176x144&amp;compression=50&amp;fps=15&amp;videokeyframeinterval=30&amp;videobitrate=120&amp;videomaxbitrate=128&amp;videobitratepriority=quality&amp;audio=0" ><input type="hidden" name="root_StreamProfile_S3_Default_Name" value="Mobile" ><input type="hidden" name="root_StreamProfile_S3_Default_Description" value="Mobile device settings." ><input type="hidden" name="root_StreamProfile_S3_Default_Parameters" value="videocodec=h264&amp;resolution=176x144&amp;compression=50&amp;fps=15&amp;videokeyframeinterval=30&amp;videobitrate=120&amp;videomaxbitrate=128&amp;videobitratepriority=quality&amp;audio=0" >
  949. </form>
  950. <form name="listFormInt"><input type="hidden" name="root_ImageSource_NbrOfSources" value="1" ><input type="hidden" name="root_ImageSource_I0_Name" value="Camera" ><input type="hidden" name="root_ImageSource_I0_Sensor_WhiteBalance" value="auto" ><input type="hidden" name="root_ImageSource_I0_Sensor_Exposure" value="auto" ><input type="hidden" name="root_ImageSource_I0_Sensor_MaxExposureTime" value="166667" ><input type="hidden" name="root_ImageSource_I0_Sensor_MinExposureTime" value="0" ><input type="hidden" name="root_ImageSource_I0_Sensor_MaxGain" value="100" ><input type="hidden" name="root_ImageSource_I0_Sensor_MinGain" value="0" ><input type="hidden" name="root_ImageSource_I0_Sensor_ExposureValue" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_ExposurePriority" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_ColorDesaturation" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_Brightness" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_Contrast" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_ColorLevel" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_Sharpness" value="50" ><input type="hidden" name="root_ImageSource_I0_Sensor_BacklightCompensation" value="yes" ><input type="hidden" name="root_ImageSource_I0_Sensor_DynamicPixelCorrection" value="yes" ><input type="hidden" name="root_ImageSource_I0_Sensor_ExposureWindow" value="auto" ><input type="hidden" name="root_ImageSource_I0_Sensor_CustomExposureWindow_Weight" value="100" >
  951. </form>
  952. <form name="listFormExt">
  953. </form>
  954.  
  955. <SCRIPT LANGUAGE="JavaScript">
  956. <!--
  957.  
  958. // Calculate the number of external sources that are supported by this browser
  959. var ext_sources = 0;
  960. ext_sources = document.listFormExt.elements.length/3;
  961. // -->
  962.  
  963. <form name="listFormSeq">
  964. </form>
  965.  
  966. <SCRIPT LANGUAGE="JavaScript">
  967. <!--
  968.  
  969. // Calculate the number of sequence sources that are supported by this browser
  970. var seq_sources = 0;
  971. if (document.listFormSeq.length > 0 )  {
  972.  if (browser == "IE") {
  973.    seq_sources = document.listFormSeq['root_Sequence_S0_NbrOfSources'].value;
  974.  } else {
  975.    for (var i = 0; i < document.listFormSeq['root_Sequence_S0_NbrOfSources'].value; i++) {
  976.      var type = document.listFormSeq['root_Sequence_S0_Source_S' + i + '_Type'].value;
  977.      if (type != 'Ext') {
  978.        seq_sources++;
  979.      } else {
  980.        var num = document.listFormSeq['root_Sequence_S0_Source_S' + i + '_Number'].value;
  981.        var path = document.listFormExt['root_ExternalVideo_E' + num + '_ImagePath'].value;
  982.        if ((path.indexOf("mpeg4") == -1) || (path.indexOf("h264") == -1)) {
  983.          seq_sources++;
  984.        }
  985.      }
  986.    }
  987.  }
  988. }
  989. // -->
  990.  
  991. <form name="lightsForm"><input type="hidden" name="root_LightControl_L0_Name" value="Light" ><input type="hidden" name="root_LightControl_L0_DriverType" value="pwm" ><input type="hidden" name="root_LightControl_L0_SourceType" value="whiteled" ><input type="hidden" name="root_LightControl_L0_Driver" value="pa18" ><input type="hidden" name="root_LightControl_L0_Button" value="actinact" ><input type="hidden" name="root_LightControl_L0_Activate" value="-100" ><input type="hidden" name="root_LightControl_L0_Inactivate" value="-0" ><input type="hidden" name="root_LightControl_L0_PulseTime" value="0" >
  992. </form>
  993. <form name="formlightlevel0"
  994.      id="formlightlevel0"
  995.      action="/axis-cgi/lightcontrol.cgi" target="Temp">
  996.   <input type="hidden" name="light" value="1">
  997.   <input type="hidden" name="level" value="0">
  998. </form>
  999.  
  1000.  
  1001. <form name="outputsForm"><input type="hidden" name="root_IOPort_I0_Configurable" value="no" ><input type="hidden" name="root_IOPort_I0_Direction" value="input" ><input type="hidden" name="root_IOPort_I0_Input_Name" value="PIR sensor" ><input type="hidden" name="root_IOPort_I0_Input_Trig" value="closed" >
  1002. </form>
  1003.  
  1004. <form name="audioclipsForm"><input type="hidden" name="root_MediaClip_MaxGroups" value="40" ><input type="hidden" name="root_MediaClip_M20_Name" value="Camera clicks" ><input type="hidden" name="root_MediaClip_M20_Location" value="/etc/audioclips/camera_clicks16k.au" ><input type="hidden" name="root_MediaClip_M20_Type" value="audio" ><input type="hidden" name="root_MediaClip_M21_Name" value="Pssst, Psst!" ><input type="hidden" name="root_MediaClip_M21_Location" value="/etc/audioclips/pssst_psst16k.au" ><input type="hidden" name="root_MediaClip_M21_Type" value="audio" ><input type="hidden" name="root_MediaClip_M22_Name" value="Froggy sound" ><input type="hidden" name="root_MediaClip_M22_Location" value="/etc/audioclips/frog16k.au" ><input type="hidden" name="root_MediaClip_M22_Type" value="audio" ><input type="hidden" name="root_MediaClip_M23_Name" value="Crazy monkey" ><input type="hidden" name="root_MediaClip_M23_Location" value="/etc/audioclips/monkey16k.au" ><input type="hidden" name="root_MediaClip_M23_Type" value="audio" ><input type="hidden" name="root_MediaClip_M24_Name" value="Crazy cow!" ><input type="hidden" name="root_MediaClip_M24_Location" value="/etc/audioclips/muu16k.au" ><input type="hidden" name="root_MediaClip_M24_Type" value="audio" ><input type="hidden" name="root_MediaClip_M25_Name" value="Baby is hungry" ><input type="hidden" name="root_MediaClip_M25_Location" value="/etc/audioclips/tindra_is_hungry_16k.au" ><input type="hidden" name="root_MediaClip_M25_Type" value="audio" >
  1005. </form>
  1006.  
  1007. <table width="100%" cellspacing=0 cellpadding=0 border=0><tr><td align="center">
  1008. <form name="WizardForm" method="POST">
  1009. <input type="hidden" name="root_Layout_Trigger_T0_Enabled" value="no">
  1010. <input type="hidden" name="root_Layout_Trigger_T1_Enabled" value="">
  1011. <input type="hidden" name="root_Layout_Trigger_T2_Enabled" value="">
  1012. <input type="hidden" name="root_Layout_Trigger_T3_Enabled" value="">
  1013. <input type="hidden" name="root_Layout_Trigger_T4_Enabled" value="">
  1014. <input type="hidden" name=amount value="0">
  1015.  
  1016.   <br>
  1017.   <table width=774 cellspacing=0 cellpadding=0 border=0>
  1018.     <tr>
  1019.       <td colspan=2><img src="/pics/line_corner_lt_5x5px.gif" width=5 height=5 border=0 alt=""></td>
  1020.       <td colspan=4 background="/pics/line_t_100x5px.gif"><img src="/pics/line_t_100x5px.gif" width=768 height=5 border=0 alt=""></td>
  1021.       <td colspan=2><img src="/pics/line_corner_rt_5x5px.gif" width=5 height=5 border=0 alt=""></td>
  1022.     </tr>
  1023.     <tr>
  1024.       <td class="lineBg"><img src="/pics/blank.gif" width="1" border=0 alt=""></td>
  1025.       <td><img src="/pics/blank.gif" width="4" height=1 border=0 alt=""></td>
  1026.       <td colspan=4 valign="middle" align="left" width="100%">
  1027.         <table border=0 cellspacing=0 cellpadding=0 width="100%">
  1028.           <tr>
  1029.             <td><a href="http://www.axis.com/" target=_blank><IMG src="/pics/logo_70x29px.gif" width=68 height=29 border=0 title="Axis" alt="Axis"></A></td>
  1030.             <td class="topTitle" align="center" id="view_prodName">AXIS M1031-W Network Camera</td>
  1031.             <td align="right">
  1032.               <table cellpadding=0 cellspacing=5 border=0>
  1033.                 <tr>
  1034.                   <td><a href="/" target="_top" class="linkActive" id="view_LViewTxt">Live View</a></td><td>|</td>
  1035.                   <td>
  1036. <SCRIPT LANGUAGE="JavaScript">
  1037. <!--
  1038.  document.write('<a href="')
  1039.  // Workaround for IE7 that doesn't handle location.host correctly with IPv6.
  1040.  var address = "";
  1041.  var axoper_new = "http";
  1042.  var axadmin_new = "http";
  1043.  
  1044.  var the_hostname = document.location.hostname
  1045.  if ((document.location.protocol == 'http:') && ((axoper_new == 'https') || (axoper_new == 'both') || (axadmin_new == 'https') || (axadmin_new == 'both'))) {
  1046.    var the_https_port = '443'
  1047.    address = 'https://'
  1048.    address += the_hostname
  1049.    if (the_https_port != '443') {
  1050.      address += ':' + the_https_port
  1051.    }
  1052.  }
  1053.  document.write(address)
  1054.  
  1055.  document.write("/operator/basic.shtml?id=22" class="linkInActive" target="_top" id="view_SetTxt1">Setup</a>")
  1056. // -->
  1057.  
  1058.                   </td><td>|</td>
  1059.                   <td><a href="#" onClick="javascript:launch('/help/liveview_h.shtml?cntrlQue='); return false;" class="linkInActive" id="view_HelpTxt">Help</a></td>
  1060.                 </tr>
  1061.               </table>
  1062.             </td>
  1063.           </tr>
  1064.         </table>
  1065.       </td>
  1066.  
  1067.       <td><img src="/pics/blank.gif" width="4" border=0 alt=""></td>
  1068.       <td class="lineBg"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1069.     </tr>
  1070.     <tr>
  1071.       <td class="lineBg"><img src="/pics/blank.gif" width=1 height=5 alt=""></td>
  1072.       <td colspan=6><img src="/pics/blank.gif" width=1 height=5 alt=""></td>
  1073.       <td class="lineBg"><img src="/pics/blank.gif" width=1 height=5 alt=""></td>
  1074.     </tr>
  1075.     <tr>
  1076.       <td colspan=2><img src="/pics/line_corner_lb_5x5px.gif" width=5 height=5 alt=""></td>
  1077.       <td colspan=4 background="/pics/line_b_100x5px.gif"><img src="/pics/blank.gif" width=764 height=5 alt=""></td>
  1078.       <td colspan=2><img src="/pics/line_corner_rb_5x5px.gif" width=5 height=5 alt=""></td>
  1079.     </tr>
  1080.     <tr>
  1081.       <td colspan=8><img src="/pics/blank.gif" width=1 height=5 border=0 alt=""></td>
  1082.     </tr>
  1083.  
  1084.     <tr>
  1085.       <td colspan=8>
  1086.         <table width="100%" cellpadding=0 cellspacing=0 border=0>
  1087.           <tr>
  1088.  
  1089. <SCRIPT LANGUAGE="JavaScript">
  1090. <!--
  1091.  
  1092.  
  1093. // Functions to include to handle selection of stream profiles
  1094.  
  1095. var globProfileBase = "root_StreamProfile_S";
  1096.  
  1097. function profileSelectUrlpars(listform,editform)
  1098. {
  1099.  group = editform.streamprofile.options[editform.streamprofile.selectedIndex].value;
  1100.  if (group == "none") {
  1101.    return "";
  1102.  }
  1103.  name = globProfileBase + group + "_Parameters";
  1104.  return listform[name].value;
  1105. }
  1106.  
  1107. function profileParseOption(optionString,option)
  1108. {
  1109.  var res = "";
  1110.  option += "=";
  1111.  var start = optionString.indexOf(option);
  1112.  if (start >= 0) {
  1113.    start += option.length;
  1114.     var end = optionString.indexOf("&", start);
  1115.    if (end >= 0)
  1116.      res = optionString.substring(start, end);
  1117.    else
  1118.      res = optionString.substring(start);
  1119.  }
  1120.  return res;
  1121. }
  1122.  
  1123. function profileCurrentMax(listform)
  1124. {
  1125.  var grpMax = 0;
  1126.  for (i = 0; i < listform.elements.length; i++) {
  1127.    var par = listform.elements[i].name;
  1128.    pos1 = globProfileBase.length;
  1129.    pos2 = par.indexOf('_', globProfileBase.length);
  1130.    var grp = 1 * (par.substring(pos1, pos2));
  1131.    if (grp > grpMax) {
  1132.      grpMax = grp;
  1133.    }
  1134.  }
  1135.  return grpMax;
  1136. }
  1137.  
  1138. function profileOptionsWrite(listform,selopt)
  1139. {
  1140.  var grpMax = profileCurrentMax(listform);
  1141.  for (grp = 0; grp <= grpMax; grp++) {
  1142.    elemName = globProfileBase + grp + "_Name";
  1143.    if (document.getElementsByName(elemName).length > 0) {
  1144.      name = listform[elemName].value;
  1145.      if (name == selopt) {
  1146.        document.write("<option value='" + grp + "' selected>" + name + "</option>");
  1147.      } else {
  1148.        document.write("<option value='" + grp + "'>" + name + "</option>");
  1149.      }
  1150.    }
  1151.  }
  1152. }
  1153.  
  1154. function profileSelectWrite(listform,selopt)
  1155. {
  1156.  var grpMax = profileCurrentMax(listform);
  1157.  
  1158.  /* Write start */
  1159.  document.write("<select name='streamprofile' size='1'>");
  1160.  document.write("<option selected value='none'>-----------</option>");
  1161.  
  1162.  profileOptionsWrite(listform,selopt);
  1163.  
  1164.  /* Write end */
  1165.  document.write('</select>');
  1166. }
  1167.  
  1168. function getProfileGrp(listform,theProfile)
  1169. {
  1170.  var grpMax = profileCurrentMax(listform);
  1171.  var grp = "Profile group not found"
  1172.  for (i=0; i<=grpMax; i++) {
  1173.    elemName = globProfileBase + i + "_Name";
  1174.    if (document.getElementsByName(elemName).length > 0) {
  1175.      name = listform[elemName].value;
  1176.      if (name == theProfile)
  1177.        var grp = i
  1178.    }
  1179.  }
  1180.  return grp;
  1181. }
  1182.  
  1183. function newVideoFormat()
  1184. {
  1185.  newVideoFormatCam('1');
  1186. }
  1187.  
  1188. function newVideoFormatCam(cam)
  1189. {
  1190.  var url = "";
  1191.  var options = "";
  1192.  var selvalue = getProfileGrp(document.profileForm,"");
  1193.  if (selvalue == "MJPEG") {
  1194.    url = '/mjpg/video.mjpg';
  1195.  }  else if (selvalue == "MPEG4") {
  1196.    url = '/axis-media/media.amp?videocodec=mpeg4';
  1197.  } else if (selvalue == "H264") {
  1198.    url = '/axis-media/media.amp?videocodec=h264';
  1199.  } else {
  1200.    var val = document.profileForm["root_StreamProfile_S" + selvalue + "_Name"].value;
  1201.    if (val) {
  1202.      options = "&streamprofile=" + val;
  1203.      val = profileParseOption(document.profileForm["root_StreamProfile_S" + selvalue + "_Parameters"].value,"audio");
  1204.      if (val == "1") {
  1205.        options += "&audio=yes";
  1206.      } else if (val == "0") {
  1207.        options += "&audio=no";
  1208.      }
  1209.    }
  1210.    var enc = profileParseOption(document.profileForm["root_StreamProfile_S" + selvalue + "_Parameters"].value,"videocodec");
  1211.    if ((enc == "jpeg")) {
  1212.      url = '/mjpg/video.mjpg';
  1213.    }  else if ((enc == "mpeg4")) {
  1214.      url = '/axis-media/media.amp?videocodec=mpeg4';
  1215.    }  else if ((enc == "h264") || (enc == "")) {
  1216.      url = '/axis-media/media.amp?videocodec=h264';
  1217.    }
  1218.  }
  1219.  changeView(url, cam, '', '1', options);
  1220. }// $root_Layout_ShowVideoFormatDropDown = yes
  1221.  
  1222.  
  1223. var form;
  1224.  
  1225. // Draw the light buttons
  1226. form = document.lightsForm;
  1227.  
  1228. var LightStateStr = "0";
  1229. var LightState = LightStateStr.split(",");
  1230. var lightlevel0Slider = null;
  1231.  
  1232. function initSliders()
  1233. {
  1234. }
  1235.  
  1236.  
  1237. function slider_onChange(name)
  1238. {
  1239.  if (name.substr(0, 10) == 'lightlevel') {
  1240.    var submitform = document.getElementById('form'+name);
  1241.    if (submitform) {
  1242.      input = document.getElementById(name);
  1243.      submitform.level.value = input.value;
  1244.      submitform.submit();
  1245.    }
  1246.  }
  1247. }
  1248.  
  1249.  
  1250. function validateLightLevel0() {
  1251.  var value = parseInt(document.getElementById("lightlevel0").value, 10);
  1252.  return (value != NaN && value >= 0 && value <= 100);
  1253. }
  1254.  
  1255. {
  1256.  var k = 0;
  1257.  
  1258.    try {
  1259.      var LightName = form["root_LightControl_L" + k + "_Name"].value;
  1260.      var unit = form["root_LightControl_L" + k + "_PulseTime"].value;
  1261.      var buttontype = form["root_LightControl_L" + k + "_Button"].value;
  1262.      var activate = form["root_LightControl_L" + k + "_Activate"].value;
  1263.      var inactivate = form["root_LightControl_L" + k + "_Inactivate"].value;
  1264.  
  1265.      for (j = unit.length-1; j >= 0; j--) {
  1266.        if (unit.charAt(j) == "h") {
  1267.          var value = parseInt(unit) * 10;
  1268.          var displayValue = parseFloat(unit)/100;
  1269.          break;
  1270.        } else if (unit.charAt(j) == "s") {
  1271.          var value = parseInt(unit) * 1000;
  1272.          var displayValue = parseInt(unit);
  1273.          break;
  1274.        }
  1275.      }
  1276.  
  1277.      if (buttontype != "none") {
  1278.        drawBoxHeader(LightName);
  1279.        if (buttontype == "actinact") {
  1280.          drawBoxToggleButton('/pics/on_blue_button_27x27px.gif',
  1281.                              '/pics/on_blue_pressed_button_27x27px.gif',
  1282.                              "Activate " + [LightName],
  1283.                              '/axis-cgi/io/lightcontrol.cgi?action=L' + [k + 1] + ':'+ activate,
  1284.                              'buttonOn0' + k,
  1285.                              '/pics/off_blue_button_27x27px.gif',
  1286.                              '/pics/off_blue_pressed_button_27x27px.gif',
  1287.                              "Inactivate " + [LightName],
  1288.                              '/axis-cgi/io/lightcontrol.cgi?action=L' + [k + 1] + ':'+ inactivate,
  1289.                              'buttonOff0' + k,
  1290.                              LightState[k] != '0');
  1291.  
  1292.        } else if (buttontype == "pulse") {
  1293.          drawBoxButton('/pics/pulse_blue_button_27x27px.gif',
  1294.                        "Pulse&nbsp;" + [LightName] + " for " + [displayValue] + " second(s)",
  1295.                        '/axis-cgi/io/lightcontrol.cgi?action=L' + [k+1] + ':' + activate + ',' + 'w'+value + ','+inactivate,
  1296.                        'PulseOff0' + [k],
  1297.                        '/pics/pulse_blue_button_pressed_27x27px.gif');
  1298.        } else if (buttontype == "slider") {
  1299.          var id = 'lightlevel'+k;
  1300.          document.write('<td nowrap valign="middle">' +
  1301.                         '<img src="/pics/slider_left.gif" width="14" height="14" id="'+id+'-left">'+
  1302.                         '<img src="/pics/slider_bg_151x14px.gif" width="151" height="14" id="'+id+'-bg">'+
  1303.                         '<img src="/pics/slider_handle.gif" width="5" height="14" id="'+id+'-handle" style="display: none">'+
  1304.                         '<img src="/pics/slider_right.gif" width="14" height="14" id="'+id+'-right">'+
  1305.                         '</td>');
  1306.          document.write('<td><input type="hidden" id="'+id+'" name="'+id+'" size="4" value="'+Math.round(parseFloat(LightState[k]))+'"></td>');
  1307.          document.getElementById(id+'-handle').style.display = "inline";
  1308.        }
  1309.  
  1310.        drawBoxFooter();
  1311.        drawBoxSpacer();
  1312.      }
  1313.    }
  1314.    catch(e) {}
  1315. }
  1316.  
  1317.  
  1318. // Draw the AudioClip selector and Play button
  1319. form = document.audioclipsForm;
  1320.  drawBoxHeader("Audio clip");
  1321.  document.write('<td nowrap valign="middle">');
  1322.  document.writeln('<select name="audioclip" onchange="javascript:changeaudioclip(this)">');
  1323.  document.writeln('<option value="">----------</option>');
  1324.  clipArray = new Array();
  1325.  var clipix = 0;
  1326.  for (var i = 0; i < form.elements.length; i++) {
  1327.    if ( form.elements[i].name.indexOf("_Name") > 0) {
  1328.      var index = form.elements[i].name.indexOf("_Name");
  1329.      var preParamName = form.elements[i].name.substring(0,  index);
  1330.      var clipName = form.elements[i].value;
  1331.      var clipNr = (isNaN(preParamName.substr(preParamName.length-2,1)) ? preParamName.substr(preParamName.length-1, 1) : preParamName.substr(preParamName.length-2, 2));
  1332.      clipArray[clipix] = clipName + ':' + clipNr;
  1333.      clipix++;
  1334.    }
  1335.  }
  1336.  
  1337.  clipArray = clipArray.sort();
  1338.  for (var i = 0; i < clipArray.length; i++) {
  1339.    var clipName = clipArray[i];
  1340.    var j = clipName.lastIndexOf(":");
  1341.    var clipNr = clipName.substring(j+1);
  1342.    clipName = clipName.substring(0, j);
  1343.    document.write("<option value="" + clipNr + "">" + clipName + "</option>");
  1344.  }
  1345.  document.writeln('</select>');
  1346.  document.write('</td><td nowrap valign="middle">');
  1347.  drawBoxButton('/pics/play_blue_button_27x27px.gif',
  1348.                "Play Audio",
  1349.                '/axis-cgi/playclip.cgi?clip=',
  1350.                'audioclipbutton',
  1351.                '/pics/play_blue_button_27x27px.gif',
  1352.                '');
  1353.  document.write('</td>');
  1354.  drawBoxFooter();
  1355.  drawBoxSpacer();
  1356.  
  1357.  
  1358.  
  1359. // Draw the sequence buttons and the list of sources
  1360.  
  1361. if ((1 > 1) ||
  1362.    (document.listFormExt.elements.length > 0)) {
  1363.  drawBoxHeader("Source", true);
  1364. } else {
  1365.  drawBoxHeader('&nbsp;', true);
  1366. }
  1367.  
  1368. if ((("" != "yes") || ("" == "yes")) && (seq_sources > 1)) {
  1369.  drawBoxButton('/pics/button_sequence_27x27px.gif',
  1370.                "Click to view sequence mode",
  1371.                'JavaScript:sequence()');
  1372.  drawBoxButton('/pics/button_one_gray_27x27px.gif',
  1373.                "Sequence mode - Stopped");
  1374. } else {
  1375.  drawBoxButton('/pics/space.gif', null, null, null, null, null, 1);
  1376. }
  1377. document.write('<td valign="middle" align="left">&nbsp;</td>');
  1378.  
  1379. document.write('<td valign="middle" align="left">');
  1380. listVideoSources()
  1381. document.write('</td>');
  1382.  
  1383. drawBoxFooter();
  1384.  
  1385. // Draw the trigger buttons
  1386.  
  1387. function addTriggerButtons(button_name, indx)
  1388. {
  1389.  if (document.WizardForm["root_Layout_Trigger_T" + indx + "_Enabled"].value != "yes") {
  1390.    return;
  1391.  }
  1392.  
  1393.  drawBoxSpacer();
  1394.  drawBoxHeader(button_name);
  1395.  drawBoxButton('/pics/on_blue_button_27x27px.gif',
  1396.                button_name + " on",
  1397.                '/axis-cgi/io/virtualinput.cgi?action=' + [indx + 6] + ':/',
  1398.                'buttonOn',
  1399.                '/pics/on_blue_pressed_button_27x27px.gif');
  1400.  drawBoxButton('/pics/off_blue_button_27x27px.gif',
  1401.                button_name + " off",
  1402.                '/axis-cgi/io/virtualinput.cgi?action=' + [indx + 6] + ':\',
  1403.                'buttonOff',
  1404.                '/pics/off_blue_pressed_button_27x27px.gif');
  1405.  drawBoxFooter();
  1406. }
  1407.  
  1408. addTriggerButtons("Trigger", 0);
  1409.  
  1410. // -->
  1411.  
  1412.           </tr>
  1413.         </table>
  1414.       </td>
  1415.     </tr>
  1416.  
  1417.     <tr>
  1418.       <td colspan=8><img src="/pics/blank.gif" width=1 height=5 border=0 alt=""></td>
  1419.     </tr>
  1420.     <tr>
  1421.       <td colspan=2><img src="/pics/line_corner_lt_5x5px.gif" width=5 height=5 border=0 alt=""></td>
  1422.       <td colspan=4 background="/pics/line_t_100x5px.gif"><img src="/pics/blank.gif" width=768 height=5 border=0 alt=""></td>
  1423.       <td colspan=2><img src="/pics/line_corner_rt_5x5px.gif" width=5 height=5 border=0 alt=""></td>
  1424.     </tr>
  1425.  
  1426.     <tr>
  1427.       <td width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=1 border=0 alt=""></td>
  1428.       <td valign="top" align="center" colspan=6 width=773>
  1429.  
  1430.         <table border=0 cellpadding=0 cellspacing=0 width=776 height="100%">
  1431.           <tr height=197>
  1432.             <td valign="top"></td>
  1433.             <td valign="top" class="normalText" align="center" rowspan=2 colspan="2">
  1434.            <div id="filterinstallocation"></div>
  1435.  
  1436. <SCRIPT LANGUAGE="JavaScript">
  1437. <!--
  1438. video('/axis-media/media.amp?videocodec=h264');
  1439.  
  1440. // -->
  1441.     </form> <!-- wizardForm -->
  1442.     </td>
  1443.   </tr>
  1444.       </td>
  1445.       <td width=4><img src="/pics/blank.gif" width=1 height=1 border=0 alt=""></td>
  1446.       <td width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=1 border=0 alt=""></td>
  1447.     </tr>
  1448.     <!-- ################################################################ -->
  1449.     <!-- Defines the table width -->
  1450.     <tr>
  1451.       <td colspan=1 width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1452.       <td colspan=1 width=4><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1453.       <td colspan=1 width=180><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1454.       <td colspan=1 width=1><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1455.       <td colspan=1 width=199><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1456.       <td colspan=1 width=384><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1457.       <td colspan=1 width=4><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1458.       <td colspan=1 width=1 class="lineBg"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1459.     </tr>
  1460.     <!-- ################################################################ -->
  1461.     <tr>
  1462.       <td colspan=2><img src="/pics/line_corner_lb_5x5px.gif" width=5 height=5 alt=""></td>
  1463.       <td colspan=1 background="/pics/line_b_100x5px.gif"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1464.       <td colspan=2 background="/pics/line_b_100x5px.gif"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1465.       <td colspan=1 background="/pics/line_b_100x5px.gif"><img src="/pics/blank.gif" width=1 height=1 alt=""></td>
  1466.       <td colspan=2><img src="/pics/line_corner_rb_5x5px.gif" width=5 height=5 alt=""></td>
  1467.     </tr>
  1468.     <tr>
  1469.       <td colspan=8><img src="/pics/blank.gif" width=1 height=5 border=0 alt=""></td>
  1470.     </tr>
  1471.     <tr>
  1472.       <td width=1><img src="/pics/blank.gif" width="1" height="1" border=0 alt=""></td>
  1473.       <td colspan=6 valign="middle" align="left">
  1474.         <table cellpadding=0 cellspacing=5 border=0>
  1475.           <tr>
  1476.             <td>&nbsp;</td>
  1477.           </tr>
  1478.         </table>
  1479.       </td>
  1480.       <td width=1><img src="/pics/blank.gif" width="1" height="1" border=0 alt=""></td>
  1481.     </tr>
  1482.   </table>
  1483. </td></tr></table>
  1484. </body>
  1485. </html>
Latest pastes
19 hours ago
19 hours ago
21 hours ago
2 days ago
4 days ago