function ErasePhoto(photoid, referenceid) {
        if (confirm("Удалить фотографию?")) document.location.href = "/user/reference/?reference_id=" + referenceid + "&photo_id=" + photoid + "&do=delete_photo";
}
function ModerateReferencePhoto(photoid, path) {
        if (confirm("Удалить фотографию?")) document.location.href = path + "/?photo_id=" + photoid + "&do=delete_photo";
}

function SubmitForm(obj_id) {
        var el = document.getElementById(obj_id);
        el.submit();
}


function showDiv(divid) {
        if (document.getElementById(divid).style.display=='none') document.getElementById(divid).style.display='inline';
        else document.getElementById(divid).style.display='none';
}

function loadCalendar(d) {
        $("#calendars").html("<br /><br />").css("background", "url(/images/loadingAnimation.gif) center top no-repeat").load("/bin/calendar.php?date=" + d, function(){ $(this).css("background", ""); });
}

