<!--

	//================================================================================================
	// VARIABLES DECLARATION
	//================================================================================================	
	var openVideo = false;
	var flagEnlargement = false;
	var galleryImageIDs;
	var videoPos, videoTotal;
	
	//================================================================================================
	// AJAX FUNCTIONS
	//================================================================================================		
	function showEnlargementImage(type, id)
	{
		var div = $('container_enlargement');
		var url = "get_enlargement.asp";
		var data = "type=" + type + "&imageID=" + id
		var images;
		
		if (type == "gallery")
		{
			data = data + "&prevID=" + getGalleryPrevImageID(id) + "&nextID=" + getGalleryNextImageID(id)
		}		
				
		var req = new Request( {url: '' + url,

			onSuccess: function(txt) {
			
				$(div).set('html', txt);

				showEnlargement();

				if (type == "gallery")
				{
					var img_path = $('gallery_image_address').get('text');
								
					/* preloading */  			
					images = [ img_path ];

					//create the asset.images
					assetImages = new Asset.images(images, {  
						onComplete: function() { 							
							images.each(function(imgsrc) {  
								new Element('img',{ src: imgsrc, height: 445, style: 'width:auto; height:445px;' }).inject($('enlargement_image')); 
								
								var w = window.getWidth() / 2 - 445;
								var h = window.getHeight() / 2 - 225;
								var top;

								if (h < 0) {
									top = 0;
								}
								else
								{
									top = h + window.getScrollTop();
								}
								
								$('container_enlargement').setStyle('top', top + 'px');
								$('container_enlargement').setStyle('left', (w + 210) + 'px');
							});		
						}				
					});
				}
				
			},

			onFailure: function() {
				$(div).set('html', '<div class="ajax_white">Error loading... Please refresh the browser</div>');
			}

		}).send(data);
	}	
	
	function sendBuyEvent(firstname, surname, qty, amount, email, phone, address, suburb, state, postcode, country, subscribe, comment, listID)
	{
		var url = "process.asp";

		var data = "process=buyevent";
		data = data + "&listID=" + listID;
		data = data + "&firstname=" + firstname;
		data = data + "&surname=" + surname;
		data = data + "&qty=" + qty;
		data = data + "&amount=" + amount;
		data = data + "&email=" + email;
		data = data + "&phone=" + phone;
		data = data + "&address=" + address;
		data = data + "&suburb=" + suburb;
		data = data + "&state=" + state;
		data = data + "&postcode=" + postcode;
		data = data + "&country=" + country;
		data = data + "&comment=" + escape(comment);
		data = data + "&subscribe=" + subscribe;
		data = data + "&sid=" + Math.random();		
		
		var req = new Request( {method: 'get', url: '' + url, 

			onSuccess: function(txt) {			
				//alert(txt);
				$('txtMessage').set('text', 'Success! Redirecting to Paymate.com...');
				
				window.location = txt;
				
				var form = document.buyform;
				form.firstname.value = "";
				form.surname.value = "";
				form.qty.value = "0";
				form.amount.value = "0";
				form.email.value = "";
				form.phone.value = "";
				form.address.value = "";
				form.suburb.value = "";
				form.state.value = "";
				form.postcode.value = "";
				form.country.value = "";
				form.comment.value = "";
				form.subscribe.value = "";
				
				$('totalAmount').set('html', '0');
			},

			onRequest: function() {
				$('txtMessage').set('text', 'Processing donation. Please wait...');
			},
			
			onFailure: function() {
				alert("Error connecting to server. Please refresh this page...");
			}
			
		}).send(data);
	}	
	
	function sendShoutLunchFightHunger(firstname, surname, amount, company, email, phone, address, suburb, state, postcode, country, subscribe, listID)
	{
		var url = "process.asp";

		var data = "process=shoutlunch";
		data = data + "&listID=" + listID;
		data = data + "&firstname=" + firstname;
		data = data + "&surname=" + surname;
		data = data + "&amount=" + amount;
		data = data + "&company=" + company;
		data = data + "&email=" + email;
		data = data + "&phone=" + phone;
		data = data + "&address=" + address;
		data = data + "&suburb=" + suburb;
		data = data + "&state=" + state;
		data = data + "&postcode=" + postcode;
		data = data + "&country=" + country;
		data = data + "&subscribe=" + subscribe;
		data = data + "&sid=" + Math.random();		
		
		var req = new Request( {method: 'get', url: '' + url, 

			onSuccess: function(txt) {			
				//alert(txt);
				$('txtMessage').set('text', 'Success! Redirecting to Paymate.com...');
				
				window.location = txt;
				
				var form = document.shoutlunchform;
				form.firstname.value = "";
				form.surname.value = "";
				form.donationAmount.value = "0";
				form.company.value = "";
				form.email.value = "";
				form.phone.value = "";
				form.address.value = "";
				form.suburb.value = "";
				form.state.value = "";
				form.postcode.value = "";
				form.country.value = "";
				form.subscribe.checked = "";
			},

			onRequest: function() {
				$('txtMessage').set('text', 'Processing donation. Please wait...');
			},
			
			onFailure: function() {
				alert("Error connecting to server. Please refresh this page...");
			}
			
		}).send(data);
	}
	function sendDonation(firstname, surname, amount, email, phone, address, suburb, state, postcode, name_behalf, address_behalf, occasion, subscribe, listID)
	{
		var url = "process.asp";

		var data = "process=donation";
		data = data + "&listID=" + listID;
		data = data + "&firstname=" + firstname;
		data = data + "&surname=" + surname;
		data = data + "&amount=" + amount;
		data = data + "&email=" + email;
		data = data + "&phone=" + phone;
		data = data + "&address=" + address;
		data = data + "&suburb=" + suburb;
		data = data + "&state=" + state;
		data = data + "&postcode=" + postcode;
		data = data + "&name_behalf=" + name_behalf;
		data = data + "&address_behalf=" + escape(address_behalf);
		data = data + "&occasion=" + escape(occasion);
		data = data + "&subscribe=" + subscribe;
		data = data + "&sid=" + Math.random();		
		
		var req = new Request( {method: 'get', url: '' + url, 

			onSuccess: function(txt) {			
				//alert(txt);
				$('txtMessage').set('text', 'Success! Redirecting to Paymate.com...');
				
				window.location = txt;
				
				var form = document.donateform;
				form.firstname.value = "";
				form.surname.value = "";
				form.amount.value = "";
				form.email.value = "";
				form.phone.value = "";
				form.address.value = "";
				form.suburb.value = "";
				form.state.value = "";
				form.postcode.value = "";
				form.name_behalf.value = "";
				form.address_behalf.value = "";			
				form.occasion.value = "";			
				form.subscribe.value = "";			
			},

			onRequest: function() {
				$('txtMessage').set('text', 'Processing donation. Please wait...');
			},
			
			onFailure: function() {
				alert("Error connecting to server. Please refresh this page...");
			}
			
		}).send(data);
	}	
	
	function sendEnquiry(firstname, surname, email, address, phone, subject, comment)
	{
		var url = "process.asp";

		var data = "process=enquiry";
		data = data + "&firstname=" + firstname;
		data = data + "&surname=" + surname;
		data = data + "&email=" + email;
		data = data + "&address=" + escape(address);
		data = data + "&phone=" + phone;
		data = data + "&subject=" + subject;
		data = data + "&comment=" + escape(comment);
		data = data + "&sid=" + Math.random();		
		
		var req = new Request( {method: 'get', url: '' + url, 

			onSuccess: function(txt) {			
				alert(txt);
				
				var form = document.enquiryform;
				form.firstname.value = "";
				form.surname.value = "";
				form.email.value = "";
				form.address.value = "";
				form.phone.value = "";
				form.subject.value = "";
				form.comment.value = "";			
			},
			
			onFailure: function() {
				alert("Error connecting to server. Please refresh this page...");
			}
			
		}).send(data);
	}	
	
	function signupNewsletter(listID, fullname, email)
	{
		var url = "process.asp";

		var data = "process=recipient";
		data = data + "&action=add-jax";
		data = data + "&listID=" + listID;
		data = data + "&fullname=" + fullname;
		data = data + "&email=" + email;
		data = data + "&sid=" + Math.random();		
		
		var req = new Request( {method: 'get', url: '' + url, 

			onSuccess: function(txt) {
				alert(txt);
				
				//reset form
				var form = document.signupform;				
				form.fullname.value = "Your name";
				form.email.value = "Your email address";
			},
			
			onFailure: function() {
				alert("Error connecting to server. Please refresh this page...");
			}
			
		}).send(data);
	}	
	
	//================================================================================================
	// FORM FUNCTIONS
	//================================================================================================
	function updateTotalSeats()
	{
		var form = document.buyform;		
		var c_num = form.qty.value;
		var c_tens, c_total, c_rest;
		
		c_total = 0;
		
		// if (c_num >= 10)
		// {
			// c_tens = (c_num / 10).toInt();
			// c_total = c_tens * 1800;
			// c_rest = c_num - (c_tens * 10);
		// }
		// else
		// {
			// c_rest = c_num;
		// }
		
		// c_total = c_total + (c_rest * 185);
		
		if (c_num >= 10)
		{
			c_total = c_num * 180; //disc
		}
		else
		{
			c_total = c_num * 185;
		}
		
		$('totalAmount').set('html', '' + c_total);
		form['amount'].value = c_total;
	}
	function shareNow()
	{
		var valid = true;
		var form = document.shareform;
		
		if (form.donationAmount.value < 5)
		{
			valid = false;
			alert("Please enter a minimum of $5 for the donation amount.");
		}
		
		if (valid) form.submit();
	}
	
	function amountChange(field)
	{
		var amount = field.value;
		var da_bag = "bag_0";
		var form = document.shareform;
		
		var amt_meals = 0;
		var amt_families = 0;
		var amt_weight = 0;
		var amt_dollar = 0;
		
		if (amount >= 150)
		{
			da_bag = "bag_6";
		}
		else if (amount >= 100)
		{
			da_bag = "bag_5";
		}
		else if (amount >= 70)
		{
			da_bag = "bag_4";
		}
		else if (amount >= 50)
		{
			da_bag = "bag_3";
		}
		else if (amount >= 30)
		{
			da_bag = "bag_2";
		}
		else if (amount >= 10)
		{
			da_bag = "bag_1";
		}
		else
		{
			da_bag = "bag_0";
		}
		
		if (amount < 0 || amount == '') amount = 0;
		
		amt_meals = amount;
		amt_families = parseInt(amount / 4);
		amt_weight = Math.round(amount * 0.3);
		amt_dollar = '$' + amount;
		
		form.mealsAmount.value = amt_meals;
		form.familiesTotal.value = amt_families;
		form.weightAmount.value = amt_weight;
		form.dollarAmount.value = amt_dollar;
		
		$$('.bag_box').setStyle('display', 'none');
		$(da_bag).setStyle('display', 'block');
		
	}
	
	function submitBuyEvent()
	{
		var form = document.buyform;

		var c_listID = form.listID.value;
		var c_firstname = form.firstname.value;
		var c_surname = form.surname.value;
		var c_qty = form.qty.value;
		var c_amount = form.amount.value;
		var c_email = form.email.value;
		var c_phone = form.phone.value;
		var c_address = form.address.value;
		var c_suburb = form.suburb.value;
		var c_state = form.state.value;
		var c_postcode = form.postcode.value;
		var c_country = form.country.value;
		var c_comment = form.comment.value;
		var c_subscribe = form.subscribe.value;

		var valid = true;

		if (c_qty <= 0)
		{
			valid = false;
			alert("Please make sure you have entered a valid quantity.");
		}
		else if (c_firstname == "")
		{
			valid = false;
			alert("Please make sure you have entered your first name.");
		}
		else if (c_surname == "")
		{
			valid = false;
			alert("Please make sure you have entered your last name.");
		}
		else if (c_amount == "")
		{
			valid = false;
			alert("Please make sure you have entered the amount of donation.");
		}
		else if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(c_email)))
		{
			valid = false;
			alert("Please make sure you have entered a valid e-mail address.");
		}
		else if (c_phone == "")
		{
			valid = false;
			alert("Please make sure you have entered your contact phone number.");
		}
		else if (c_address == "")
		{
			valid = false;
			alert("Please make sure you have entered your street address.");
		}
		else if (c_suburb == "")
		{
			valid = false;
			alert("Please make sure you have entered your suburb.");
		}
		else if (c_state == "")
		{
			valid = false;
			alert("Please make sure you have entered your state.");
		}
		else if (c_postcode == "")
		{
			valid = false;
			alert("Please make sure you have entered your postcode.");
		}
		else if (c_country == "")
		{
			valid = false;
			alert("Please make sure you have entered your country.");
		}

		if (valid == true)
		{
			sendBuyEvent(c_firstname, c_surname, c_qty, c_amount, c_email, c_phone, c_address, c_suburb, c_state, c_postcode, c_country, c_subscribe, c_comment, c_listID);
		}
	}	
	
	function submitShoutLunchFightHunger()
	{
		var form = document.shoutlunchform;

		var c_listID = form.listID.value;
		var c_firstname = form.firstname.value;
		var c_surname = form.surname.value;
		var c_amount = form.donationAmount.value;
		var c_company = form.company.value;
		var c_email = form.email.value;
		var c_phone = form.phone.value;
		var c_address = form.address.value;
		var c_suburb = form.suburb.value;
		var c_state = form.state.value;
		var c_postcode = form.postcode.value;
		var c_country = form.country.value;
		var c_subscribe = form.subscribe.value;

		var valid = true;

		if (c_amount == "")
		{
			valid = false;
			alert("Please make sure you have entered the amount of donation.");
		}
		else if (c_firstname == "")
		{
			valid = false;
			alert("Please make sure you have entered your first name.");
		}
		else if (c_surname == "")
		{
			valid = false;
			alert("Please make sure you have entered your last name.");
		}
		else if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(c_email)))
		{
			valid = false;
			alert("Please make sure you have entered a valid e-mail address.");
		}
		else if (c_phone == "")
		{
			valid = false;
			alert("Please make sure you have entered your contact phone number.");
		}
		else if (c_address == "")
		{
			valid = false;
			alert("Please make sure you have entered your street address.");
		}
		else if (c_suburb == "")
		{
			valid = false;
			alert("Please make sure you have entered your suburb.");
		}
		else if (c_state == "")
		{
			valid = false;
			alert("Please make sure you have entered your state.");
		}
		else if (c_postcode == "")
		{
			valid = false;
			alert("Please make sure you have entered your postcode.");
		}
		else if (c_country == "")
		{
			valid = false;
			alert("Please make sure you have entered your country.");
		}

		if (valid == true)
		{
			sendShoutLunchFightHunger(c_firstname, c_surname, c_amount, c_company, c_email, c_phone, c_address, c_suburb, c_state, c_postcode, c_country, c_subscribe, c_listID);
		}
	}
	
	function submitDonation()
	{
		var form = document.donateform;

		var c_listID = form.listID.value;
		var c_firstname = form.firstname.value;
		var c_surname = form.surname.value;
		var c_amount = form.amount.value;
		var c_email = form.email.value;
		var c_phone = form.phone.value;
		var c_address = form.address.value;
		var c_suburb = form.suburb.value;
		var c_state = form.state.value;
		var c_postcode = form.postcode.value;
		var c_name_behalf = form.name_behalf.value;
		var c_address_behalf = form.address_behalf.value;
		var c_occasion = form.occasion.value;
		var c_subscribe = form.subscribe.value;
		var c_type = form.donationtype.value;

		var valid = true;

		if (c_amount == "")
		{
			valid = false;
			alert("Please make sure you have entered the amount of donation.");
		}
		else if (c_firstname == "")
		{
			valid = false;
			alert("Please make sure you have entered your first name.");
		}
		else if (c_surname == "")
		{
			valid = false;
			alert("Please make sure you have entered your last name.");
		}
		else if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(c_email)))
		{
			valid = false;
			alert("Please make sure you have entered a valid e-mail address.");
		}
		else if (c_phone == "")
		{
			valid = false;
			alert("Please make sure you have entered your contact phone number.");
		}
		else if (c_address == "")
		{
			valid = false;
			alert("Please make sure you have entered your street address.");
		}
		else if (c_suburb == "")
		{
			valid = false;
			alert("Please make sure you have entered your suburb.");
		}
		else if (c_state == "")
		{
			valid = false;
			alert("Please make sure you have entered your state.");
		}
		else if (c_postcode == "")
		{
			valid = false;
			alert("Please make sure you have entered your postcode.");
		}

		if (valid == true)
		{
			if (c_type == "Recurring donation")
			{
				if (form.dd.value == "DD")
				{
					valid = false;
					alert("Please make sure you have selected the day.");
				}
				else if (form.mm.value == "MM")
				{
					valid = false;
					alert("Please make sure you have selected the month.");
				}
				else if (form.yyyy.value == "YYYY")
				{
					valid = false;
					alert("Please make sure you have selected the year.");
				}
			}		
			
			if (valid == true)
			{
				form.submit();
				//sendDonation(c_firstname, c_surname, c_amount, c_email, c_phone, c_address, c_suburb, c_state, c_postcode, c_name_behalf, c_address_behalf, c_occasion, c_subscribe, c_listID);
			}
		}
	}	
	
	function submitEnquiry()
	{
		var form = document.enquiryform;

		var c_firstname = form.firstname.value;
		var c_surname = form.surname.value;
		var c_email = form.email.value;
		var c_address = form.address.value;
		var c_phone = form.phone.value;
		var c_subject = form.subject.value;
		var c_comment = form.comment.value;

		var valid = true;

		if (c_firstname == "")
		{
			valid = false;
			alert("Please make sure you have entered your first name.");
		}
		else if (c_surname == "")
		{
			valid = false;
			alert("Please make sure you have entered your surname.");
		}
		else if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(c_email)))
		{
			valid = false;
			alert("Please make sure you have entered a valid e-mail address.");
		}
		else if (c_subject == "")
		{
			valid = false;
			alert("Please make sure you have entered a subject.");
		}
		else if (c_comment == "")
		{
			valid = false;
			alert("Please make sure you have entered comment or enquiry.");
		}

		if (valid == true)
		{
			sendEnquiry(c_firstname, c_surname, c_email, c_address, c_phone, c_subject, c_comment);
		}
	}
	
	function submitSignUpNewsletter()
	{
		var form = document.signupform;
		
		var c_listID = form.listID.value;
		var c_fullname = form.fullname.value;
		var c_email = form.email.value;
		
		var valid = true;
		
		if ((c_fullname == "") || (c_fullname == "Your name")) 
		{
			valid = false;
			alert("Please make sure you have entered your full name.");		
		} 
		else if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(c_email)))
		{
			valid = false;
			alert("Please make sure you have entered a valid e-mail address.");		
		}
		
		if (valid == true) 
		{
			signupNewsletter(c_listID,c_fullname,c_email);
		}		
	}
	
	//================================================================================================
	// LAYOUT FUNCTIONS 
	//================================================================================================			
	function resetMenuPositions()
	{
		var w = window.getWidth() / 2 - 495;
		$('ourimpactContainer').setStyle('left', (w + 385) + 'px');
		$('donatefoodContainer').setStyle('left', (w + 500) + 'px');
		$('donatemoneyContainer').setStyle('left', (w + 615) + 'px');
		$('getinvolvedContainer').setStyle('left', (w + 730) + 'px');
		$('contactContainer').setStyle('left', (w + 845) + 'px');
		if ($chk($('countriesContainer')))
		{			
			$('countriesContainer').setStyle('left', (w + 750) + 'px');
		}			
	}	
	
	function selectDonationType(type)
	{
		if (type == 'Recurring donation')
		{
			$('div_frequency').setStyle('display', 'block');
			$('div_gifts').setStyle('display', 'none');
		}
		else if (type == 'Gift certificate')
		{
			$('div_frequency').setStyle('display', 'none');
			$('div_gifts').setStyle('display', 'block');
		}
		else
		{
			$('div_frequency').setStyle('display', 'none');
			$('div_gifts').setStyle('display', 'none');
		}
	}
	function getGalleryPrevImageID(imageID)
	{
		var idx = galleryImageIDs.indexOf('' + imageID);

		idx--;
		if (idx < 0) 
		{
			idx = galleryImageIDs.length - 1;
		}
		return galleryImageIDs[idx];		
	}
	
	function getGalleryNextImageID(imageID)
	{
		var idx = galleryImageIDs.indexOf('' + imageID);
		
		idx++;
		if (idx >= galleryImageIDs.length) 
		{
			idx = 0;
		}
		return galleryImageIDs[idx];		
	}	
	
	function backToTop()
	{
		new Fx.Scroll($(window)).toTop();
	}

	function gotoContent(id)
	{
		if ($chk($('content_' + id)))
		{			
			new Fx.Scroll($(window)).toElement('content_' + id);
		}	
	}
	
	function showEnlargement()
	{
		if (!flagEnlargement)
		{
			$('container_enlargement').setStyle('display', 'block');
			flagEnlargement = true;
		}
	}
	
	function hideEnlargement()
	{
		if (flagEnlargement)
		{
			$('container_enlargement').setStyle('display', 'none');
			flagEnlargement = false;
		}
	}	

	function toggleEnlargement()
	{
		if (!flagEnlargement)
		{
			showEnlargement();
		}
		else
		{
			hideEnlargement();
		}
	}	
	
	function prevVideo()
	{
		videoPos--;
		if (videoPos <= 0) videoPos = videoTotal;
		gotoVideo();
	}

	function nextVideo()
	{
		videoPos++;
		if (videoPos > videoTotal) videoPos = 1;
		gotoVideo();
	}	
	
	function gotoVideo()
	{
		if ($chk($('video_' + videoPos)))
		{
			var myPlayer;
			
			//stop all videos
			
			// if ($('video_1').getStyle('display') == 'block')
			// {
				// myPlayer = document.getElementById('player_1');
				// myPlayer.stopVideo();
			// }
			// if ($chk($('player_2')))
			// {
				// myPlayer = document.getElementById('player_2');
				// myPlayer.stopVideo();
			// }
			// if ($chk($('player_3')))
			// {
				// myPlayer = document.getElementById('player_3');
				// myPlayer.stopVideo();
			// }
			// if ($chk($('player_4')))
			// {
				// myPlayer = document.getElementById('player_4');
				// myPlayer.stopVideo();
			// }
			
			$$('.video_box').setStyle('display', 'none');
			$('video_' + videoPos).setStyle('display', 'block');			
		}
	}
	
	function showVideo()
	{
		if (!openVideo)
		{
			$('container_video').setStyle('display', 'block');
			gotoVideo();
			openVideo = true;
		}
	}	
		
	function hideVideo()
	{
		if (openVideo)
		{
			$('container_video').setStyle('display', 'none');
			openVideo = false;
		}
	}	

	function toggleVideo()
	{
		if (openVideo)
		{
			hideVideo();
		} 
		else
		{
			showVideo();
		}
	}	
	
	//================================================================================================
	// EVENTS FUNCTIONS
	//================================================================================================		
	function setupActions()
	{
		if ($chk($$('.nav_hover')[0])) 
		{				
			$$('.nav_hover').addEvents({
			
				'mouseover' : function(e) {
					this.addClass('bg_top_nav_selected');
				},
			
				'mouseout' : function(e) {
					this.removeClass('bg_top_nav_selected');
				}
				
			});					
		}		

		if ($chk($$('.subnav_link')[0])) 
		{				
			$$('.subnav_link').addEvents({
			
				'mouseover' : function(e) {
					this.setStyle('background-color', '#666666');
				},
			
				'mouseout' : function(e) {
					this.setStyle('background-color', '#333333');
				}
				
			});					
		}			
	}	
	
	function setupDraggableDivs()
	{
		if ($chk($('container_enlargement')))
		{
			var dragEnlargement = new Drag('container_enlargement');
		}
	}		

	function setupSlideshows()
	{
		if ($chk($('home_slideshow')))
		{			
			var homeShow = new Slideshow('home_slideshow', false, {delay: 4000, width: 990, height: 555});
		}	
	}
	
	//================================================================================================
	// START THIS WHEN PAGE DOM READY
	//================================================================================================		
	window.addEvents({
	
		'domready' : function(e) {
			setupActions();
			setupSlideshows();
			setupDraggableDivs();
			resetMenuPositions();
			
			if ($chk($('container_gallery_thumbs')))
			{
				galleryImageIDs = $$('.img_thumb').get('id');
			}
			
			if ($chk($('video_content')))
			{
				videoPos = 1;
				videoTotal = $$('.video_box').length;
			}	

			if ($chk($$('.bag_box')[0]))
			{
				$$('.bag_box').setStyle('display', 'none');
				$('bag_0').setStyle('display', 'block');
			}	
			
		},
		
		'resize' : function() {
			resetMenuPositions();
		}
		
	});
	

//-->
