在Firefox中读取XML-Document的问题 [英] problem with reading XML-Document in Firefox

查看:115
本文介绍了在Firefox中读取XML-Document的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Re XML,Javascript,IE,Firefox



我有一个非常简单的&小型XML文件(只有7个变量)。该代码适用于IE,但不适用于Firefox。我已经四处寻找并找到了很多替代方案,但是所有方法都有所不同,并且大部分都超出了我的竞争水平(ieg Ajax ;-()。有人可以给我一些指导 - 谢谢

展开 | 选择 | Wrap | 行号

解决方案

Heya,Gretsch。


你想要什么?代码呢?举个例子。

你的代码是做什么的,你不想让它做什么?举个例子。

你的代码是什么*不是*应该这样做?举个例子。

谢谢,

我希望代码读取XML文件中的7个变量,并允许我用它们执行计算。当我使用IE时,一切正常,但是当我使用Firefox时,它打印出我的Firefox检测到的测试消息,(所以我知道它正在找到正确的代码位),但不打印 document.write(" Save;" + save + .... 行。


这是我的XML文件的示例位:

展开 | 选择 | Wrap | 行号


hi ...


i假设xml-doc尚未准备就绪,此时您尝试检索值...看看这里您可能会看到必须检索值o nload of doc ...看看那里的例子的getmessage()函数。


亲切的问候


Re XML, Javascript, IE, Firefox
Hi,
I have a very simple & small XML file (only 7 variables). The code works for IE, but not for Firefox. I''ve search around and found lots of alternatives, but all different and mostly way above my competance level to understand (ieg Ajax;-(). Could someone give me some guidance please. - thanks

Expand|Select|Wrap|Line Numbers

解决方案

Heya, Gretsch.

What do you want your code to do? Give an example.
What is your code doing that you don''t want it to do? Give an example.
What is your code *not* doing that it is supposed to? Give an example.


Thanks,
I want the code to read in the 7 variables from the XML file and allow me to perform calculations with them. When I use IE it all works fine, but when I use Firefox it prints my "Firefox detected" test msg,(so I know it''s getting to the right bit of code) but doesnt print the document.write("Save ;" + save + .... line.

Here''s a sample bit of my XML file:

Expand|Select|Wrap|Line Numbers


hi ...

i assume that the xml-doc is not ready at this point where you try to retrieve the values ... have a look here where you might see that you have to retrieve the values onload of the doc ... have a look at the getmessage() function of the example there.

kind regards


这篇关于在Firefox中读取XML-Document的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆