(function($) {
	$.fn.objectKiller = function($params) {
	var $defaults = {
		myID: null,
		myAction: null,
		myObj: null,
		onKill: function(element){}
	};
	var $k = $.extend($defaults, $params);
	$(this).before("<div id='tempDiv' style='width:1px;height:1px'></div>");
	$("#tempDiv").load("ajaxProcessor.ashx",{ID: $k.myID, actionType: $k.myAction, object:$k.myObj},function(responseText, status) {
		$("#tempDiv").remove();	
		var checkError = $(responseText).attr("id");
			if (checkError == "error") {
				$.modal(responseText);
			} else {
				$k.onKill($k.myID);
			}																			  
																								  
																								  
	 });
																								  
																							
	};

})(jQuery);