function AccessSelector() {

	
	AccessSelector.prototype.send = function(command,container_id,classname,extra_args,success) {
 
	   url = "/access.response.php";
		 
		 
		 	 
	   if (extra_args == null) extra_args = "nil=0";
		 if (this.extra != '') extra_args += "&"+this.extra;
	   //ajaxEngine.registerAjaxElement(container_id);
	   //alert("ajaxEngine.sendRequest( 'listChange','value=" + newval +"','command=" + command +"','container_id=" + container_id +"'"+extra_args +")");  // 'value' has to be renamed
	   ////eval("ajaxEngine.sendRequest( 'listChange','value=" + newval +"','command=" + command +"','container_id=" + container_id +"'"+extra_args +")");  // 'value' has to be renamed
	   pars = "command=" + command +"&classname="+classname+"&jsname="+this.jsname+"&container_id=" + container_id +"&"+extra_args; //+Filter.getfilters();  // 'value' has to be renamed
	   
														 // need to fill the rest of the items send from ARGS
														 // should look like "order=1" ... might need to be encoded
			
		 //successFunc = "";											 
	   //alert(pars);
		 if (!success) success = this.successFunc;
		 rerror = this.reportError;
		 var myAjax = new Ajax.Updater( {success: container_id}, url, {method: 'get', parameters: pars,  onComplete:success, onFailure: rerror, evalScripts: true}); 
												 
	 }
	 
	 AccessSelector.prototype.successFunc = function(){
	   //alert("ajax success");
	 
	 }
	 
	 AccessSelector.prototype.reportError = function() {
	   alert("ajax failed");
	 }
	
	
	
	 AccessSelector.prototype.save = function(container,eid,cat_id,access,id) {
	 	stuff = "entity_id="+eid+"&";
	 	stuff+= "category_id="+cat_id+"&";
	 	stuff+= "access_level="+access+"&";
	 	stuff+= "id="+id;
	 	
	 	this.send("save",container,"",stuff); 
	
	
	 }





}
