![]() |
dhtml problem in safari
Hi,
This code works with ie but not with safari: function montre(id,this_nb,nb,shtml) { if (document.getElementById) { document.getElementById(id).style.visibility = 'visible'; } else if (document.all) { document.all[id].style.visibility = 'visible'; } else if (document.layers) { document.layers[id].visibility = 'visible'; }; var el = (document.getElementById)? document.getElementById(id): (document.all)? document.all[id]: (document.layers)? document.layers[id]: null; if (!el) return; if (typeof el.innerHTML!="undefined") { el.innerHTML = shtml; } else if (document.layers) { el.document.write(shtml); el.document.close(); } } Can someone tells me what to do to make it workm on both browsers? Thx. Pat |
Re: dhtml problem in safari
"Patrice" <manitoo@videotron.ca> wrote in message
news:e4dRd.13486$3p4.503610@wagner.videotron.net.. . : Hi, : This code works with ie but not with safari: : : : function montre(id,this_nb,nb,shtml) { : if (document.getElementById) { : document.getElementById(id).style.visibility = 'visible'; : } else if (document.all) { : document.all[id].style.visibility = 'visible'; : } else if (document.layers) { : document.layers[id].visibility = 'visible'; : : }; : : var el = (document.getElementById)? document.getElementById(id): : (document.all)? document.all[id]: (document.layers)? document.layers[id]: : null; : if (!el) return; : if (typeof el.innerHTML!="undefined") { : el.innerHTML = shtml; : } else if (document.layers) { : el.document.write(shtml); : el.document.close(); : } : : } : : Can someone tells me what to do to make it workm on both browsers? Perhaps in a DHTML or client-side j(ava)script NG, preferably with Safari support. This is ASP related (server-side scripting) at a Safari competitor newsserver. -- Roland Hall /* This information is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. */ Technet Script Center - http://www.microsoft.com/technet/scriptcenter/ WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp MSDN Library - http://msdn.microsoft.com/library/default.asp |
| All times are GMT. The time now is 01:09 AM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.