client side xslt with javascript in firefox

I am using client-side xslt to transform xml files into xhtml. There have been some hurdles but I have managed to get passed all of them except this. The problem is that when I have a simple xml file like this hello and transform it to xhtml with a simple xsl like this a title world the first alert will pop-up as "[object XMLDocument]" with firefox instead of "[object]" like it does for IE and safari. From what I gather this means that firefox does no produce a javascript html document (or html dom, not sure what the wording is). The second alert in firefox will be "undefined" but in IE and safari it is "[object]. So in firefox there is no document.forms or document.anchors etc. I know some javascript will still work, like document.getElementById, but I am afraid that more advanced stuff like ajax will not work propery if document.forms and the like do not exist. Is there a work-around for this? On my current project I am rewriting a bunch of pages to use xslt. There is a lot of javascipt already writen and changing it all to use the limited firefox javascript is not really an option if it is even possible. Thank you very much for any help.

以上就是client side xslt with javascript in firefox的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准

联系我们

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏