//Transform all Bin elements to our Ajaxified interface
Event.addBehavior({
	'#albums li a.delete': function(e)
	{
		var url=this.readAttribute('href')+"&content_type=xml";
		this.observe('click', function(event){event.stop();var confirmDelete=confirm("Are you certain you want to delete this album?");if(confirmDelete){new Ajax.Request(url,{method:'post',onCreate:function(){ajaxCursorStart();},onComplete:function(){ajaxCursorEnd();},onSuccess:function(transport){refreshById(transport.responseXML,"ul","albums");}})}},false);
	},
	
	/* GALLERY - CREATE ALBUM - AJAX FIELD VALUE CHANGE */
  '#albums li.noalbum input.ajax': function(e){this.setAttribute('value','yes');}
});
