function submit(ctrl) { if(ctrl.form != null) { ctrl.form.submit(); } } function changeImgControlPosition(sender) { /*var divLeft = document.getElementById('imageControlLeft'); var divRight = document.getElementById('imageControlRight'); if(sender.value == '0') { divLeft.innerHTML = divRight.innerHTML; divRight.innerHTML = ''; } else { divRight.innerHTML = divLeft.innerHTML; divLeft.innerHTML = ''; }*/ } function changeImgWidth() { /*var photo = document.getElementById('imgPartnerPhoto'); var width = document.getElementById('imgWidth').value; var height = document.getElementById('imgHeight').value; if(isInt(width)) photo.style.width = width; else photo.style.width = ''; if(isInt(height)) photo.style.height = height; else photo.style.height = '';*/ } function isInt(x) { var y = parseInt(x); if ( isNaN(y) ) return false; return x == y && x.toString() == y.toString(); } function showPicture(sender) { alert(sender.form); alert(sender.form.getElementById('imgPartnerPhoto')); if( sender.value != '') { var photo = document.getElementById('imgPartnerPhoto'); photo.src = sender.value; } }