	
// Sets initial page state on load
	window.onload = initialize
	
	function initialize() {
		update_bandwidth();
		update_record_rates(false);
		//validate_resolution();
		recalculate();
	}
			
	function recalculate() {
		if ( HTMLpage == 'LiveVideoBWUtilizationCalculator' )
			recalculate_bandwidth_utilization(1);
	}
		
// RESULTS CALCULATION  ---------------------------------
	function recalculate_bandwidth_utilization() {
		
// CIF scaling factor; value of 'Resolution' radio group
//set the CIF scaling factor according to the platform and video mode
		var cif_scaling_factor	= cif_factor();
// Select the appropriate 'empirical array' of bandwidth values for NC display options.
// Also set max_cameras_at_rate for PAL and NTSC
		var empirical_array	= select_empirical_array();
// Determine value to use for available (effective) bandwidth based on "Communication Link" selection
		var effective_bandwidth = select_available_bandwidth();	
// Determine values for bandwidth needed based on Intellex configuration & bandwith required by NC display settings
		var rate
		 
		var max_cameras_at_rate
		var aggregate_record_rate = $('#record_rate').val();
		if ($('#ntsc').attr('checked')) { // Video Mode = NTSC
			max_cameras_at_rate = aggregate_record_rate / 30
		}
		else { // PAL
			max_cameras_at_rate = aggregate_record_rate / 25
		}
// This is the bandwidth required from the empirical array
		var empirical_bandwidth_required = empirical_array[$('#nc_display')[0].selectedIndex];
// This sets the rate at which bandwidth is used depending on the settings of the Intellex
		var intellex_cameras_value = $('#intellex_cameras').val();
		if (intellex_cameras_value <= max_cameras_at_rate) {
			rate = empirical_bandwidth_required * intellex_cameras_value
		}
		else {
			rate = empirical_bandwidth_required * max_cameras_at_rate
		}
// Calculate consumed bandwidth
		var bandwidth_consumed
		var nc_cameras_value = $('#nc_cameras').val();
		var nc_links_value = $('#links').val();
		
		bandwidth_consumed = ( (rate/intellex_cameras_value) * nc_cameras_value * nc_links_value * cif_scaling_factor )

// Calculate remaining available bandwith
		var bandwidth_available = effective_bandwidth - bandwidth_consumed 
		
// Update the page
		if (bandwidth_available < 0 ) {
			$('#cell_12').html("Available Bandwith Exceeded by<br />" +  format_number( (-bandwidth_available).toFixed(0) ) + " Bps");
			$('#cell_12').css('color', 'red');
		}
		else {
			$('#cell_12').html(format_number(bandwidth_available.toFixed(1)) + " Bps");
			$('#cell_12').css('color', 'black');
		}
		
		$('#cell_11').html(format_number(bandwidth_consumed.toFixed(1)) + " Bps");
		
		calc_camera_update_rate() 
	}//end recalculate_incident_download

	function format_number(num)	{ 
		var n = '' + num;
		var numl  = n.length;
		var i = n.indexOf('.');
		var fract = '';
	
		if (i > -1){
			numl -= n.length-i;
			fract = n.substring(i);
		}
		if (numl > 3){
			var s, dl = numl%3;
			var str = (dl > 0) ? n.substring(0,dl):'';
			var max = Math.floor(numl/3);
			for (i=0 ; i < max ; i++){
				s = n.substring(dl+i*3,dl+i*3+3);
				str += (dl==0 && i==0) ? s : ","+s;
			}
			return str+fract;
		}else return n;
	}

	function calc_camera_update_rate() {

		var record_rate_value = $('#record_rate').val();
		var cameras_value = $('#intellex_cameras').val();
		var camera_update_rate = (record_rate_value/cameras_value)
		var invert_camera_update_rate = (1/camera_update_rate)

		if ($('#ntsc').attr('checked')) {//video mode = NTSC
			if (camera_update_rate > 30) {
				camera_update_rate = 30
			}
		}
		else { // video mode = PAL
			if (camera_update_rate > 25) {
				camera_update_rate = 25
			}
		}

		$('#camera_update_rate').html(format_number(camera_update_rate.toFixed(3)));
		$('#invert_camera_update_rate').html(format_number(invert_camera_update_rate.toFixed(3)));

	}
		
	function cif_factor() {
		var cif_scaling_factor;
		if( $( '#ntsc' ).attr('checked') ) { //Video Mode = NTSC
			if( $('#1cif').attr('checked'))
				cif_scaling_factor	= $('#1cif').val()*1.1;
			else if( $('#2cif').attr('checked'))
				cif_scaling_factor	= $('#2cif').val()*1.1;
			else if( $('#4cif').attr('checked'))
				cif_scaling_factor	= $('#4cif').val()*1.1;
		}
		else { //Video Mode = PAL
			if( $('#1cif').attr('checked'))
				cif_scaling_factor	= $('#1cif').val()*1.32;
			else if( $('#2cif').attr('checked'))
				cif_scaling_factor	= $('#2cif').val()*1.32;
			else if( $('#4cif').attr('checked'))
				cif_scaling_factor	= $('#4cif').val()*1.32;
		}
		return cif_scaling_factor;
	}
	
	function select_available_bandwidth() {
		var commincation_link_index = $('#communication_link')[0].selectedIndex;
		switch(commincation_link_index) {
			case 0: //POTS
				var bandwidth_values = new Array(9600.0, 14400.0, 25000.0, 28800.0, 33400.0, 56000.0);
				break
			case 1: //ISND
				var bandwidth_values = new Array(64000.0, 128000.0, 256000.0, 384000.0, 1536000, 1920000);
				break
			case 2: //T-n/Frame Relay
				var bandwidth_values = new Array(56000.0, 128000.0, 256000.0, 512000.0, 1536000, 44736000);
				break
			case 3: //DSL
				var bandwidth_values = new Array(144000.0, 256000.0, 640000.0, 1000000, 1500000, 7100000);
				break
			case 4: //LAN
				var bandwidth_values = new Array(10000000, 100000000 , 1000000000);
				break
		}//end switch
		var bandwidth_index = $('#bandwidth')[0].selectedIndex;
		var bandwidth = bandwidth_values[bandwidth_index];
		// percent_bandwidth_utilization; value of 'Bandwidth Utilization' radio group
		var percent_bandwidth_utilization_value = $('#utilization').val();

		// get bandwidth as bytes per second
		effective_bandwidth = bandwidth * percent_bandwidth_utilization_value;
		return effective_bandwidth;
	}//end fn
	
	function fields_second() {
		if( $('#ntsc').attr('checked') )
			fields_per_second	= $('#ntsc').val();
		else if( $('#pal').attr('checked') )
			fields_per_second	= $('#pal').val();
		return fields_per_second;
	}
	
			
	function select_empirical_array() {
		// Determine index of Quality; for use in selecting the appropriate 'empirical array'
		var quality_index; 
		if( $('#high').attr('checked'))
			quality_index	= 0;
		else if( $('#quality_normal').attr('checked'))
			quality_index	= 1;
		else if( $('#quality_extended').attr('checked'))
			quality_index	= 2;

// 	Determine Empirical Data Array to use based on: Video Mode, Sesitivity and Quality Settings.
		if ( $('#ntsc').attr('checked') ) { // Video Mode = NTSC
			if ( $('#sensitivity_high').attr('checked') ) { // Sensitivity = HIGH
				switch(quality_index) {
					case 0: // Quality = HIGH
						var empirical_array = new Array(181176,122106,97172,59583)
						break
					case 1: // Quality = NORMAL
						var empirical_array = new Array(142020,88602,60351,40796)
						break
					case 2: // Quality = EXTENDED
						var empirical_array = new Array(110180, 65626,41930,27359)
						break
				}
			}
			else { // Sensitivity = NORMAL
				switch(quality_index) {
					case 0: // Quality = HIGH
						var empirical_array = new Array(175600,118806,75972,54875)
						break
					case 1: // Quality = NORMAL
						var empirical_array = new Array(140572,90390,60153,38914)
						break
					case 2: // Quality = EXTENDED
						var empirical_array = new Array(105093,64772,41765,27140)
						break
				}
			}
		}
		else { // PAL
			if ( $('#sensitivity_high').attr('checked') ) { // Sensitivity = HIGH
				switch(quality_index) {
					case 0: // Quality = HIGH
						var empirical_array = new Array(153638,97870,68254,51361)
						break
					case 1: // Quality = NORMAL
						var empirical_array = new Array(121691,75858,54063,38686)
						break
					case 2: // Quality = EXTENDED
						var empirical_array = new Array(91751,54533,37347,28256)
						break
				}
			}
			else { // Sensitivity = NORMAL
				switch(quality_index) {
					case 0: // Quality = HIGH
						var empirical_array = new Array(147449,95642,66315,51000)
						break
					case 1: // Quality = NORMAL
						var empirical_array = new Array(118872,72060,53015,36392)
						break
					case 2: // Quality = EXTENDED
						var empirical_array = new Array(87487,54934,36131,27075)
						break
				}
			}
		}
		return empirical_array;
	}//end fn
	
	function format_number(num)	{ 
		var n = '' + num;
		var numl  = n.length;
		var i = n.indexOf('.');
		var fract = '';
	
		if (i > -1){
			numl -= n.length-i;
			fract = n.substring(i);
		}
		if (numl > 3){
			var s, dl = numl%3;
			var str = (dl > 0) ? n.substring(0,dl):'';
			var max = Math.floor(numl/3);
			for (i=0 ; i < max ; i++){
				s = n.substring(dl+i*3,dl+i*3+3);
				str += (dl==0 && i==0) ? s : ","+s;
			}
			return str+fract;
		}else return n;
	}
	

// SETTINGS CONTROL --------------------------------------------
	
	function IsNumeric(strString) {
		//  check for valid numeric strings	
		var strValidChars = "0123456789.";
		var strChar;
		var blnResult = true;
		var hasDecimal = false;
		
		if (strString.length == 0) return false;
		
		//  test strString consists of valid characters listed above
		for (i = 0; i < strString.length && blnResult == true; i++) {
			strChar = strString.charAt(i);
			if (strValidChars.indexOf(strChar) == -1) {
				blnResult = false;
			}
			if (IsDot(strChar)) {
				if (!hasDecimal) {
				hasDecimal = true;
				}
				else {
				blnResult = false;
				}
			}
		}
		return blnResult;
	}
   
	function IsDot(strChar) {
		//  check for valid numeric strings	
		var strValidChars = ".";
		var blnResult = true;
		
		//  test strString consists of valid characters listed above
		if (strValidChars.indexOf(strChar) == -1) {
			blnResult = false;
		}
		return blnResult;
	}
	
	//
	function show_video_format() {
		$('#ntsc').attr('checked');
	}
	
	
	
	// These functions call the appropriate validation routines in response to changes. 
	// This is to ensure that only legal options are available for the various combinations of 
	// platform, resolution and record rate.
		
	function video_mode_changed()
	{
		update_record_rates(false) //preserves selected index
	}
	
	function resolution_changed()
	{
		update_record_rates(true) //preserves selected value
	}
	
	// Updates 'Bandwidth' values based on selection of 'Communication Link'
	function update_bandwidth() {
		
		var selected_communication_link = $('#communication_link')[0].selectedIndex;
		var bandwidth_array = new Array()

		switch(selected_communication_link) {
			case 0: //POTS
				bandwidth_array = ["9600 Bits/Sec", "14.4 KBits/Sec", "25 KBits/Sec", "28.8 KBits/Sec", "33.4 KBits/Sec", "56.0 KBits/Sec" ]
				selected_index = 5
				break
			case 1: // ISDN
				bandwidth_array = ["64 KBits/Sec (1-B)", "128 KBits/Sec (2-B)", "256 KBits/Sec (Dual Bonded)", "384 KBits/Sec (H0)", "1.536 MBits/Sec (H11)", "1.920 MBits/Sec (H12)"]
				selected_index = 0
				break
			case 2: // T-n/Frame Relay
				bandwidth_array = ["56.0 KBits/Sec", "128 KBits/Sec", "256 KBits/Sec", "512 KBits/Sec", "1.536 MBits/Sec (T1)", "44.736 MBits/Sec (T2)"]
				selected_index = 0
				break
			case 3: // DSL
				bandwidth_array = ["144 KBits/Sec", "256 KBits/Sec", "640 KBits/Sec", "1.0 MBits/Sec", "1.5 MBits/Sec", "7.1 MBits/Sec"]
				selected_index = 5
				break
			case 4: // LAN
				bandwidth_array = ["10 Base T (10 MBits/Sec)", "100 Base T (100 MBits/Sec)", "1000 Base T (1000 MBits/Sec)"]
				selected_index = 0
				break
		}
		$('#bandwidth').children().remove();
		// set the new values for bandwidth
		var opt	= '';
		for (counter = 0; counter < bandwidth_array.length ; counter++) {
			opt	+= '<option selected value="' + bandwidth_array[counter] + '">' + bandwidth_array[counter] + '</option>';
		}
		$('#bandwidth').html(opt);
		// set initial selected index for
		$('#bandwidth')[0].selectedIndex	= selected_index;;
				
	}
		
	// Updates 'Record Rates' based on selection of 'Video Format' as NTSC or PAL
	function update_record_rates(preserve_value) {
		
		var rate_array = new Array(9)
		
		if ($('#ntsc').attr('checked')) {//video mode = NTSC
			rate_array = ["480", "240", "120", "60", "30", "15", "7", "3", "1"]
		}
		else {//video mode = PAL
			rate_array = ["400", "200", "100", "50", "25", "15", "7", "3", "1"]
		}

		var record_rate_value = $('#record_rate').val();
		var record_rate_index = $('#record_rate')[0].selectedIndex;
		
		$('#record_rate').children().remove();
		var opt	= '';
		for (counter = 0; counter < rate_array.length ; counter++) {
			opt	+= '<option selected value="' + rate_array[counter] + '">' + rate_array[counter] + ' ips</option>';
		}
		$('#record_rate').html(opt);
		
		if (!preserve_value) {
			//validate_record_rate()
			$('#record_rate ')[0].selectedIndex	= record_rate_index;
		}
		else {
			//validate_record_rate()
			$('#record_rate ').val(record_rate_value);
		}
		
	}
	
	// Validates legal 'Resolution' on selection of 'Record Rate'
	function validate_resolution() {

		var record_rate_value = $('#record_rate').val();
		$( '#1cif' ).attr( 'disabled', '' );
		$( '#2cif' ).attr( 'disabled', '' );
		$( '#4cif' ).attr( 'disabled', '' );

		if (record_rate_value == "400") { record_rate_value = "480" }
		if (record_rate_value == "200") { record_rate_value = "240" }

		switch(record_rate_value) { 
			case "480": // 'Record Rate' is set to 480 ips
				$( '#1cif' ).attr( 'checked', 'checked' ); //set 'Resolution' to 1 CIF
				$( '#2cif' ).attr( 'disabled', 'disabled' ); //disable 2 CIF
				$( '#4cif' ).attr( 'disabled', 'disabled' ); //disable 4 CIF
				break
			
			case "240": // 'Record Rate' is set to 240 ips
				if ($( '#4cif' ).attr( 'checked')) {  // if 'Resolution' is set to 4 CIF
					$( '#2cif' ).attr( 'checked', 'checked' );  // set 'Resolution' to 2 CIF
				}
				$( '#4cif' ).attr( 'disabled', 'disabled' );//disable 4 CIF
				break
		}
	}

	// Validates legal 'Record Rate' on selection of 'Resolution'
	function validate_record_rate() {
		
		var record_rate_node = document.getElementById("record_rate")
		var record_rate_value = record_rate_node.options[record_rate_node.selectedIndex].value
		var resolution_node = document.forms[1].resolution
		var selected_resolution
		
		// Determine which 'Resolution' is selected
		for (var counter = 0 ; counter < resolution_node.length ; counter++) {
			if (resolution_node[counter].checked) {
				selected_resolution = counter
			}
		}

		//alert(selected_resolution)
		switch(selected_resolution) { 
			case 2: // 'Resolution' is set to 4 CIF
				if (record_rate_node.options[0].value == "480" || record_rate_node.options[0].value == "400" ) {
					record_rate_node.options[0] = null
				}
				if (record_rate_node.options[0].value == "240" || record_rate_node.options[0].value == "200" ) {
					record_rate_node.options[0] = null
				}
				break
			case 1: // 'Resolution' is set to 2 CIF
				if (record_rate_node.options[0].value == "480" || record_rate_node.options[0].value == "400" ) {
					record_rate_node.options[0] = null
				}
				break
			case 0: // 'Resolution' is set to 1 CIF
				break
		}
	}
	
	
	function blockSubmit( e ) {
		var evt = e || window.event;
		var keyPressed = e.which || window.event.keyCode
		if ( keyPressed == 13 ) {
			// If the Enter key is pressed, convert to tab. 
			recalculate();
			//(evt == e)? e.preventDefault() : window.event.keyCode = 9; 
			if( window.event )
				window.event.keyCode = 9; 
			else
				e.preventDefault();
		} 
		else { 
			// If other than the Enter key is pressed, cancel. 
			evt.cancelBubble = true; 
		}
	}
	
	function block_tab() {
		if ( window.event.keyCode = 9 ) {
			window.event.cancelBubble = true;
		}
	}
	


	
	
// HELP SECTION ------------------------------------------------------
function top() {
	window.location.hash = "#calc"
}
	
function show_help(help_term) {
	
	var term
	var text
	
	switch(help_term) {
		
		case 'video':
				term = "Video Mode"
				text = "<p>Video Mode indicates the video standard being used - NTSC or PAL.</p>"
				break
			case 'quality':
				term = "Quality"
				text = "<p>Quality determines the tradeoff between image quality and storage space consumption. “Super” emphasizes better image quality, but at the cost of greater storage consumption and longer download times. “Extended” favors conservation of storage space and faster downloads, but at the cost of poorer image quality. “Normal” selects a balance between the two.</p>"
				break
			case 'sensitivity':
				term = "Sensitivity"
				text = "<p>Sensitivity affects how responsive Intellex is to small changes between images. This affects image resolution, storage consumption, and download times. “High” records smaller changes, resulting in better resolution, but greater storage consumption and longer download times. “Normal” ignores smaller changes, resulting in less resolution, but also decreased storage consumption and shortened download times.</p>"
				break
			case 'resolution':
				term = "Resolution"
				text = "<p>Resolution indicates the image size being recorded by Intellex. Larger image sizes yield better image resolution, while smaller image sizes save on memory and speed up downloads. If the video mode is NTSC, a setting of “1CIF” sets the image size to 352 pixels wide by 240 pixels high. “2 CIF” selects an image size of 704 x 240, and “4 CIF” sets the size at 704 x 480. If the video mode is PAL, a setting of “1CIF” sets the image size to 352 pixels wide by 288 pixels high. “2 CIF” selects an image size of 704 x 288, and “4 CIF” sets the size at 704 x 576.</p>"
				break
			case 'communication_link':
				term = "Communications Link"
				text = "<p>The Communication Link indicates the type of connection used to send data between Intellex and Network Client. The selection made here will affect the list of choices presented in the “Bandwidth” dropdown list. The link choices are as follows:</p><p><b>POTS</b> – Acronym for Plain Old Telephone Service, the traditional telephone network.</p><p><b>ISDN</b> – Stands for Integrated Services Digital Network, a system of digital phone connections.</p><p><b>T-n/Frame Relay</b> – T-n refers to a dedicated digital phone connection supporting data rates up to 1.544Mbps (T-1, also called DS1) and 45 Mbps (T-3). Frame relay is a packet-switching protocol for connecting devices on a Wide Area Network (WAN), supporting T-1 and T-3 speeds.</p><p><b>DSL</b> – Stands for Digital Subscriber Line, a data communications technology using sophisticated modulation schemes to pack data onto copper wires.</p><p><b>LAN</b> – Local Area Network, a computer network that spans a relatively small area.</p>"
				break
			case 'bandwidth':
				term = "Bandwidth"
				text = "<p>Bandwidth selects the transmission rate of the communication link between Intellex and Network Client. The choices available here are governed by the selection made in the “Communications Link” field.</p>"
				break
			case 'bandwidth_utilization':
				term = "Bandwidth Utilization"
				text = "<p>Bandwidth Utilization can be used to quantify the effect of a situation where the system administrator restricts how much of the overall network bandwidth can be used by the download process. </p>"
				break
			case 'incident_rec_rate':
				term = "Incident Record Rate"
				text = "<p>Incident Record Rate is the rate at which the camera recorded the incident. For NTSC the maximum is 30 images per second (IPS) and for PAL the maximum is 25 IPS. If the record rate changes during the incident, you can estimate the download time by approximating the overall record rate for the entire incident, or alternatively, dividing the incident into segments of constant record rates and summing the results together.</p>"
				break
			case 'incident_length':
				term = "Incident Length"
				text = "<p>Incident Length specifies the duration of the recording being downloaded.</p>"
				break
			case 'download_audio':
				term = "Download Audio"
				text = "<p>Selecting the Download Audio box indicates that Intellex will be recording audio as well as video. Recording audio will increase the download time by less than 3%.</p>"
				break
			case 'minimal':
				term = "Minimal Motion"
				text = "<p>A quiet room or hallway with an occasional occupant or traffic. Virtually no motion or change due to wind, camera motion, or camera noise.</p>"
				break
			case 'casual':
				term = "Casual Motion"
				text = "<p>A room or hallway with a couple of occupants or fairly frequent traffic. A sidewalk or street with some traffic and little motion due to wind, light, or camera noise. </p>"
				break
			case 'moderate':
				term = "Moderate Motion"
				text = "<p>A busy room or hallway with several moving occupants at a time. A street or sidewalk with moderate traffic and/or moderate motion of trees and bushes due to wind.</p>"
				break
			case 'severe':
				term = "Severe Motion"
				text = "<p>Extreme motion caused by camera motion or severe camera noise. A panning dome camera or severe wind motion in most of the image.</p>"
				break
			case 'estimated_incident':
				term = "Estimated Incident Download Information"
				text = "<p>The results displayed (for the four different motion scenarios) are as follows:</p><p><b>Incident Download Time</b> – The time required to download the incident.</p><p><b>Max. Number of Incidents Per Hour </b> – The number of incidents of this duration that could be downloaded in an hour.</p><p><b>Minutes of Video Per Hour </b> – The amount of video playback time that could be downloaded in an hour.</p><p><b>Disk Space Required per Hour </b> – The number of gigabytes of storage consumed per hour to store the incidents on the client.</p><p>Click the 'Motion' heading for information about each scenario.</p>"
				break
			case 'aggregate_record_rate':
				term = "Aggregate Record Rate"
				text = "<p>Aggregate Record Rate describes the maximum rate at which images <b>from all cameras</b> can be recorded on Intellex. For example, if the aggregate rate is set to 120 IPS, 4 cameras could be recorded at 30 IPS each. However, if 16 cameras were being recorded, each camera could only record at 7.5 IPS.</p>"
				break
			case 'intellex_cameras':
				term = "Intellex Cameras"
				text = "<p>Intellex Cameras indicates how many cameras are being recorded on Intellex. Notice that increasing this setting may actually result in a decrease in required bandwidth if it causes a lowering of the Camera Update Rate. (E.g., In NTSC, if the aggregate record rate is 120 IPS, then increasing the number of Intellex cameras from 4 to 5 results in a decrease in the camera update rate from 30 IPS to 24 IPS. The bandwidth requirement for all cameras is thereby decreased.)</p>"
				break
			case 'camera_update':
				term = "Camera Update Rate"
				text = "<p>Camera Update Rate indicates how many images per second (IPS) are being recorded on any particular camera. This is calculated by dividing the Aggregate Record Rate by the number of Intellex Cameras. Note that the maximum record rate of any single camera is limited to 30 IPS for NTSC and 25 IPS for PAL. These are considered real time rates. </p><p>In addition, the inverse calculation is displayed (seconds per image), indicating how much time elapses between each update to a camera.</p>"
				break
			case 'nc_display':
				term = "Network Client Display"
				text = "<p>Network Client Display indicates how Network Client is displaying the images (Full Screen, 2x2, 3x3, or 4x4). The more images displayed, the smaller their size. Smaller image sizes result in quicker downloads, while larger images require longer download times.</p>"
				break
			case 'nc_cameras':
				term = "Network Client Cameras"
				text = "<p>Network Client Cameras indicates how many display panes in Network Client are being refreshed with live video. The greater the number of display panes being refreshed, the greater the bandwidth requirement will be. This is true even if the same Intellex camera is being displayed multiple times in Network Client. (E.g., Intellex may be recording only one camera, but if Network Client is displaying that same camera in 16 different display panes, the bandwidth requirement will be 16 times greater than if Network Client was only displaying one pane of video.)</p>"
				break
			case 'links':
				term = "Number of Links"
				text = "<p>Number of Links indicates how many Network Clients are connected to a given Intellex. For purposes of calculating bandwidth requirements, this setting assumes that all the Network Clients have exactly the same settings with respect to Network Client Display and Network Client Cameras. The greater the number of links there are, the greater the bandwidth requirements will be.</p>"
				break
			case 'total_bandwidth':
				term = "Total Required Bandwidth"
				text = "<p>Total Bandwidth Required indicates how much bandwidth is needed to download live video from Intellex to Network Client given the configuration settings specified.</p>"
				break
			case 'remaining_bandwidth':
				term = "Available Bandwidth Remaining"
				text = "<p>Available Bandwidth Remaining indicates the difference between the total available bandwidth (adjusted for any bandwidth utilization limitation) and the total required bandwidth. If the total required bandwidth exceeds the available bandwidth, then Available Bandwidth Remaining will indicate the excessive amount in red.</p>"
				break
			default:
				term = "Undefined"
				text = "<p>No help text defined.</p>"
	}
	
	document.getElementById('help_term').innerHTML = term
	document.getElementById('help_text').innerHTML = text
	window.location.hash = "#help"

}

