
function ShowAllNews(queryURL, queryField, title, selectFunction, renderTo, renderNewsItemTo){
	
	
	/*
	var mappingElement = 'url';
	var queryURL = 'XmlGMServlet?action_type=get_info&action=get_technical_docs';
	var queryField = 'file';
	var title = "delete icon file";
	*/
	
	
	
	var selectFunction = 
		function(This, rowIndex, e){
			var id = this.store.getAt(rowIndex).get('id');
			loadNewsItemIntoDivElem(id,'show_news_container');
		};
	
	
	this.renderNewsItemTo = renderNewsItemTo;
	
	var showNewsFrameSetTitleCodificationText = getLanguageForElement("showNewsFrameSetTitleCodificationText", selectedLangId);
	var showNewsTitleCodificationText = getLanguageForElement("showNewsTitleCodificationText", selectedLangId);
	var showNewsDateCodificationText = getLanguageForElement("showNewsDateCodificationText", selectedLangId);
	var showNewsHeaderCodificationText = getLanguageForElement("showNewsHeaderCodificationText", selectedLangId);
	
	//var deleteButtonText = getLanguageForElement("deleteButtonText", selectedLangId);					
	//var titleI18N = getLanguageForElement(title, selectedLangId);					
	//var titleI18N = title;//getLanguageForElement(title, selectedLangId);	

	this.fileRecord = new Ext.data.Record.create([
			{name: "date", mapping: "date", type:'string'},
			{name: "header", mapping: "header", type:'string'},
			{name: "content", mapping: "content", type:'string'},
			{name: "id", mapping: "id", type:'string'}
	]);
	
	this.proxy = new Ext.data.HttpProxy({url: queryURL});
    // create the Data Store
    this.store = new Ext.data.Store({
        // load using HTTP
        proxy: this.proxy,
        // the return will be XML, so lets set up a reader
        reader: new Ext.data.XmlReader({
               // records will have a "category" tag
               record: queryField
           }, this.fileRecord)
    });			

	this.store.load();


	this.grid = new Ext.grid.GridPanel({
		store: this.store,
	    columns: [
			{header: showNewsDateCodificationText, dataIndex: 'date', sortable: true},
			{header: showNewsHeaderCodificationText, dataIndex: 'header', width: 360, sortable: true}
	    ],
	    height:130,
	    width:480,
		title: showNewsTitleCodificationText
	});		

	this.grid.addListener('rowdblclick',selectFunction, this);
	
	this.fieldSet = null;
	
	this.fieldSet = new Ext.form.FieldSet({
		xtype: 'fieldset',
		title: showNewsFrameSetTitleCodificationText,
		collapsible: false,
		collapsed: false,
		autoHeight: true,
		bodyStyle: 'text-align:left;',
		items: [this.grid]
	});
	
	this.showNews = new Ext.Panel({
	        width: 505,	
			autoHeight : true,
			bodyBorder: false,
			border: false,		
			items: [this.fieldSet]
	});
		
	this.showNews.render(renderTo);
}


