function loadAjaxSelect(this_i, next_id, others, first_line, table_name){
	
	if(this_i.value = undefined || this_i.value == '' || this_i.value == '0'){
		$("#" + next_id).attr('disabled', true).empty( );
		if(others != ''){
			temp = others.split(';');
			for( i=0; i < temp.length; i++){
				$("#" + temp[i]).empty().attr('disabled', true);
			}
		}
		return;
	}else{
		$("#" + next_id).attr('disabled', false);
	}
	var send_url = 'http://dev.poppworks.ee/www.karol.ee/service/selectList.php?first_line=' + first_line + '&table_name=' + table_name;
	$("#" + next_id).empty();
	if(others != ''){
		temp = others.split(';');
		for( i=0; i < temp.length; i++){
			$("#" + temp[i]).empty().attr('disabled', true);
		}
	}
	//$("#ajax_debug_box").load(send_url.replace(" ", "%20"), { }, function(){
//	 });
	$("#" + next_id).load(send_url.replace(" ", "%20"), { }, function(){
	   $("#" + next_id).attr('disabled', false);
	 });
}
function preloadAjaxSelect(next_id, first_line, table_name, select_id){
	var send_url = 'http://dev.poppworks.ee/www.karol.ee/service/selectList.php?first_line=' + first_line + '&table_name=' + table_name + '&select_id' + select_id;
	$("#" + next_id).load(send_url.replace(" ", "%20"));
}
