rhyspaterson Posted July 21, 2008 Share Posted July 21, 2008 Hey lads, We use IE6 as the standard browser in our SOE at work (so i have been developing for it). However i just noticed this the other day: <script type="text/javascript"> function parseXML() { try //Internet Explorer { xmlDoc=new ActiveXObject("Microsoft.XMLDOM"); } catch(e) { try //Firefox, Mozilla, Opera, etc. { xmlDoc=document.implementation.createDocument("","",null); } catch(e) { alert(e.message); return; } } xmlDoc.async=false; xmlDoc.load("scheduled_files/required_files/printers.xml"); document.getElementById("clear").innerHTML=xmlDoc.getElementsByTagName("clear")[0].childNodes[0].nodeValue; document.getElementById("attention").innerHTML=xmlDoc.getElementsByTagName("attention")[0].childNodes[0].nodeValue; document.getElementById("critical").innerHTML=xmlDoc.getElementsByTagName("critical")[0].childNodes[0].nodeValue; } </script> .... <div class="navitem"> <ul> <li class="green"><span id="clear">?</span> are clear</li> <li class="yellow"><span id="attention">?</span> require attention</li> <li class="red"><span id="critical">?</span> are critical</li> </ul> </div> The '?'s are updated fine in IE6, but not FF3. Obviously it is some quite basic change, but cross browser javascript is all still quite new to me The XML file looks as such: <printers> <clear>48</clear> <attention>21</attention> <critical>17</critical> <total>86</total> </printers> Suggestions? Cheers Quote Link to comment Share on other sites More sharing options...
lemmin Posted July 22, 2008 Share Posted July 22, 2008 The problem is probably in the way that you are calling the function. Could you post your code for that? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.