Click to See Complete Forum and Search --> : xml working in IE, not in Firefox 1.5.0.2


Divyakedia
08-08-2006, 06:01 AM
Hi,
I am learning xml thru the net. I made an xml, included it in an html file. All works fine in IE, but Firefox shows just the table which is made in the html file. Maybe firefox doesn't include the xml or something.Is there any other way of calling xml in Firefox.
I read the post by 'ravi' but the answers don't satisfy me.
I've attached the zip that contains the xml and html.

Charles
08-08-2006, 06:13 AM
It is sad, but true. Firefox does not fully support XML & XHTML.

Divyakedia
08-08-2006, 06:17 AM
So, do u mean to say that the thing that i've made won't work at all.
If yes, pls what is the alternative. ( to chk browser and redirect to a diff page?)

raviganesh91221
08-14-2006, 12:02 AM
Use the below mentioned code in ur html page. Actually u must have differrent codes for loading XML in IE and firefox seperately.
The first one is for firefox and next for IE. Try this out and reply me

if (document.implementation && document.implementation.createDocument)
{
xmlDoc = document.implementation.createDocument("","",null);
var isLoaded = xmlDoc.load(article);
if (isLoaded == true) { displayXML(); }
}

You will need to make a similar check for IE :

if (window.ActiveXObject)
{
xmlDoc = new ActiveXObject('Microsoft.XMLDOM');
xmlDoc.async="false";
while (xmlDoc.readyState != 4) {} // readyState will be set to 4 when the document is loaded
xmlDoc.load(article);
displayXML();
}

Divyakedia
08-14-2006, 01:26 AM
Hi ravi,
I just chked the code for FF. Unfortunately it is not working. I'm working on Dreamweaver 8 and the reference also didn't provide any help.