function hidePanel(el,count=null) { var info = el.parentNode.children[1]; if (info.style.display=="none") { info.style.display="block"; el.className = "content_title_expanded"; if (count) el.innerHTML=el.innerHTML.replace(" ("+count+")",""); } else { info.style.display="none"; el.className = "content_title_unexpanded"; if (count) el.innerHTML+=" ("+count+")"; } } function show_write_textarea() { var el = document.getElementById('write'); if (el.style.display == "none") { el.style.display = "block"; } else { el.style.display = "none"; } } function edit_post(id, wid) { var el = document.getElementById('text'+wid+'_'+id); var ed = document.getElementById('text_edit'+wid+'_'+id); if (el.style.display == "none") { el.style.display = "block"; ed.style.display = "none"; } else { el.style.display = "none"; ed.style.display = "block"; } } document.addEventListener("DOMContentLoaded", function() { //BEGIN u("#_photoDelete").on("click", function(e) { var formHtml = "
"; formHtml += ""; formHtml += "
"; u("body").append(formHtml); MessageBox("Внимание", "Удаление нельзя отменить. Вы действительно уверены в том что хотите сделать?", [ "Да", "Нет" ], [ (function() { u("#tmpPhDelF").nodes[0].submit(); }), (function() { u("#tmpPhDelF").remove(); }), ]); return e.preventDefault(); }); }); //END ONREADY DECLS