function add_favorites (id, url, text) {
	new Ajax.Request(
		url, { 
			method: 'get',
			onSuccess: function(transport) {
				if (transport.responseText == "true") $(id).update (text);
			}
		}
	);

	return false;
}

function delete_favorites (id, url) {
	if (confirm ('Weet u het zeker?'))
	{
		new Ajax.Updater(
			id,
			url, { 
				method: 'get'
			}
		);
	}

	return false;
}

function delete_photo (i, url, filename)
{
	if (confirm ('Weet u het zeker?'))
	{
		new Ajax.Updater(
			'div_foto_' + i,
			url, { 
				method: 'post',
				parameters: { 
					'filename': filename, 
					'i': i
				},
				evalScripts: true
			}
		);
	}

	return false;
}

function subscribe_form (id, target, url)
{
	new Ajax.Updater(
		target,
		url, { 
			method: 'post',
			parameters: $(id).serialize(),
			evalScripts: true
		}
	);

	return false;
}