/** * @name: main.js * @author: Neomi T * @copyright: inManage LTD * @since: October 11, 2007 * @desc: Main JS function */ function findPosX(obj){ var curleft = 0; if (obj.offsetParent){ while (obj.offsetParent){ curleft += obj.offsetLeft; //curtop += obj.currentStyle.borderWidth; obj = obj.offsetParent; } }else{ if (obj.x) curleft += obj.x; } return curleft; } function findPosY(obj){ var curtop = 0; if (obj.offsetParent){ while (obj.offsetParent){ curtop += obj.offsetTop; //curtop += obj.currentStyle.borderHeight; obj = obj.offsetParent; } }else{ if (obj.y) curtop += obj.y; } return curtop; } function update_mailing(){ var email = document.getElementById("email").value; if (!IsEmail(email)) { alert("כתובת המייל אינה תקינה"); document.getElementById("email").value = ""; document.getElementById("email").focus(); } else { document.mailinglist.submit(); } } function del_val(obj, value){ if(value == 'הוספת מייל לרשימת תפוצה' || value == 'כתובתך נוספה בהצלחה !') { obj.value = ""; obj.style.color = "#e4e4e4"; } }