// JavaScript Document

var IndustryNews = new Class(
{
	objCategory:		null,
	objLocation:		null,	
	objOrder:			null,		

	initialize:			function()
	{
		this.objCategory = $('frm_select-category');
		if(this.objCategory)
		{
			this.objCategory.addEvent('change', function()
													{
														objIndustryNewsManager.addCriterion(this.get('name'), this.get('value'));
													});
		}
		
		this.objLocation = $('frm_select-location');		
		if(this.objLocation)
		{
			this.objLocation.addEvent('change', function()
													{
														objIndustryNewsManager.addCriterion(this.get('name'), this.get('value'));
													});	
		}	
		
		this.objOrder = $('frm_select-sort');		
		if(this.objOrder)
		{
			this.objOrder.addEvent('change', function()
													{
														objIndustryNewsManager.addCriterion(this.get('name'), this.get('value'));
													});	
		}		
	},
	
	addCriterion:		function(strSource, strValue)
	{
		var strAlert = strSource+"="+strValue;
		
		if(strAlert != "")
		{
			document.location = document.location.toString()+"?"+strAlert;
		}
	}
});

var objIndustryNewsManager = null;

window.addEvent('domready' , function()
							  {
							  
							  	//objIndustryNewsManager = new IndustryNews();
							  
							  });