简体   繁体   English

IE / Firefox / Opera之间的模糊Javascript区别

[英]Obscure Javascript difference between IE / Firefox / Opera

Within a "cloaked" site, using obj.innerHTML = something to change the contents of a div seems to screw up the div's position in Firefox and Opera. 在一个“隐蔽”站点中,使用obj.innerHTML = something更改div内容的obj.innerHTML = something似乎使div在Firefox和Opera中的位置obj.innerHTML = something

Best way to understand the problem is by seeing the code in action. 理解问题的最佳方法是查看实际的代码。 Go to http://www.guggs.net/index_redirected.htm in IE, Firefox or Opera and everything looks as it should. 在IE,Firefox或Opera中访问http://www.guggs.net/index_redirected.htm ,一切看起来都应该正确。

Hit one of the links in IE and everything is still fine, but in Firefox the page gets misaligned and there's no way of getting it back into shape. 点击IE中的链接之一,一切仍然很好,但是在Firefox中,页面未对齐,无法使其恢复正常。

Hit one of the links in Opera and the misalignment happens but if you then hit another link the page is OK again and remains so however many links you hit. 在Opera中点击其中一个链接会发生未对齐的情况,但是如果您再点击另一个链接,则该页面将再次正常运行,因此无论您点击了多少链接,该页面仍然有效。

If however you go straight to http://www.sensetech.me.uk/guggs which is the page behind the "cloak" it's all fine whichever browser you use and however many links you hit. 但是,如果您直接转到http://www.sensetech.me.uk/guggs (位于“斗篷”后面的页面),则无论使用哪种浏览器,无论点击多少链接,都可以。

Help ! 救命 !

  1. validate 验证
  2. I see no difference in F 3.6.10 on Mac 我在Mac上看到F 3.6.10没什么区别
  3. fix at least this: 至少解决此问题:

Warning: Expected end of value but found ','. 警告:期望值的结尾,但找到“,”。 Error in parsing value for 'padding'. 解析“ padding”的值时出错。 Declaration dropped. 声明被放弃。 Source File: /guggs/css.css Line: 39 源文件:/guggs/css.css行:39

td {
    font: 9pt verdana;
    color:#665544;
    padding: 0px, 0px, 0px, 5px;
}

Issue resolved. 问题解决了。

Nothing do with the Javascript ! 与Java无关! FireFox and Opera were tripping due to earlier PHP code intended to prevent users coming in through anything other than the index page. 由于早期的PHP代码旨在防止用户通过索引页面以外的其他内容进入,因此FireFox和Opera跳闸了。 Works OK when the site isn't cloaked so I'm not sure exactly what the problem is, but for the moment I've removed the code, which isn't anything like vital. 当站点未隐藏时可以正常工作,因此我不确定到底是什么问题,但是目前我已删除了代码,这并不是很重要。

Thanks for your time, people ! 谢谢您的宝贵时间!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 IE和Firefox之间的JavaScript差异 - Javascript difference between IE and Firefox IE和Mozilla Firefox之间的Javascript行为差异? - Javascript behaviour difference between IE and Mozilla Firefox? javascript在chrome / opera / IE中不起作用,但是firefox非常好! - javascript not working in chrome/opera/IE but firefox is excellent! 如何在JavaScript中区分Opera和Opera Mini - How to make difference between Opera and Opera Mini in JavaScript HTML / JavaScript简单重定向-可以在IE / Opera中运行,但不能在Chrome / Firefox中运行 - HTML/Javascript simple redirect -works in IE/Opera but not in Chrome/Firefox Javascript / jQuery无法在Firefox,Safari和IE中运行。 精通Opera和Chrome - Javascript/jQuery not working in Firefox, Safari and IE. Fine in Opera and Chrome 该Javascript在IE中不起作用,但在Chrome,Firefox和Opera中起作用 - This Javascript doesn't work in IE but works in Chrome, Firefox and Opera JavaScript代码仅在Chrome中有效,而在Firefox,IE,Opera和Safari中无效 - JavaScript code working only in Chrome but not in Firefox, IE, Opera and Safari Chrome可在Chrome,Opera和Edge上使用Javascript,但在FireFox或IE 11上则无法使用 - Javascript working on Chrome & Opera & Edge, but not on FireFox or IE 11 Opera和Firefox之间具有XML名称空间和xhr.responseXML的jQuery的区别 - Difference in jQuery with XML namespace and xhr.responseXML between Opera and Firefox
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM