flash - why some time javascript work on mozilla but not IE -


i have question why sometime javascript work on mozilla in case of internet explore not work.what issues here there need add in javascript please reply if body know.i have created small javascript nis not working on ie.

code

       <script language="javascript">             function toggle(divid) {                 //alert(divid);                  var ele = document.getelementbyid("toggletext");                  var text = document.getelementbyid(divid);                  var innerhtml= document.getelementbyid(divid).innerhtml;                  //alert(innerhtml);           if(ele.style.display == "block")               {         ele.style.display = "none";     text.innerhtml = document.getelementbyid(divid).innerhtml;         }            else {     ele.style.display = "block";     text.innerhtml = document.getelementbyid(divid).innerhtml;            }                           }           </script>           <div id="container"><embed height="450" width="450" wmode="transparent"  type="application/x-shockwave-flash" src="http://www.youtube.com/v/sifypqjyhv8&amp;rel=0&amp;color1=0x2b405b&amp;color2=0x6b8ab6&amp;border=1"></div>    <?php for($i=0;$i<=2;$i++)             {    ?>         <div id="displaytext<?php echo $i; ?>" onclick="javascript:toggle(this.id);"><embed height="150" width="150" wmode="transparent" type="application/x-shockwave-flash" src="http://www.youtube.com/v/sifypqjyhv8&amp;rel=0&amp;color1=0x2b405b&amp;color2=0x6b8ab6&amp;border=1"></div>       <div id="toggletext" style="display: none">change inner html</div>        <?php } ?> 

thanks

well, because different browsers have different levels of compliance javascript specifications.

see http://sputnik.googlelabs.com/


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -