Event.observe( window, 'load', function(){ var is_OPERA = ( navigator.userAgent.indexOf('Opera') != -1 ) ? true : false; var is_IE6 = ( navigator.userAgent.indexOf('MSIE 6') != -1 ) ? true : false; }); var last = false; function zoomImg(p_id,id) { var img_c = $('zoom_c'); var tmp = '
Close
'; if( last ) { var last_img = $('z_'+last); if( last == id ) last_img.show(); else { last_img.remove(); img_c.innerHTML += tmp; } } else img_c.innerHTML += tmp; img_c.show(); } function closeImg(id) { $('z_'+id).hide(); $('zoom_c').hide(); last = id; } function imgL(id) { var browser_width = document.documentElement.clientWidth || document.body.clientWidth || window.innerWidth || 0; browser_width = parseInt( browser_width ); var browser_height = document.documentElement.clientHeight || document.body.clientHeight || window.innerHeight || 0; browser_height = parseInt( browser_height ); var img = $('p_'+id); var img_div = $('z_'+id); var w = parseInt( img.getWidth() ); var h = parseInt( img.getHeight() ); var left = Math.ceil( (browser_width-w) / 2 ); var top = Math.ceil( (browser_height-h) /2 ); img_div.setStyle( {"top" : top+"px", "left" : left+"px", width : w+"px", height : h+"px"} ); img.show(); }