javascript(jQuery)的问题。适用于Firefox,但不适用于IE

时间:2022-07-03 17:31:56

I have a problem with a site I am working on, available here.

我在使用我正在处理的网站时遇到问题。

The javascript on the site works as inteded when browsed with firefox. In IE7, however, the javascript does not even get executed.

当用firefox浏览时,网站上的javascript就像有意思一样。然而,在IE7中,javascript甚至没有被执行。

As I am new to javascript I suspect that I am probably doing an obvious mistake somewhere in the code.

由于我是javascript的新手,我怀疑我可能在代码中的某个地方犯了一个明显的错误。

Any help is appreciated!

任何帮助表示赞赏!

2 个解决方案

#1


here is your problem:

这是你的问题:

$.get("ajax.php", {case: caseNr, picturenr: picNr, pictureinfo: true}, function(data){

case is a reserved word. When using hashes, always make keys be strings, and you will never get yourself in to trouble

case是保留字。使用哈希时,总是让键成为字符串,你永远不会陷入麻烦

$.get("ajax.php", {"case": caseNr, "picturenr": picNr, "pictureinfo": true}, function(data){

#2


Your problem is on line 43, karlsten.js, on IE8, so you may want to debug it on IE8, if possible, or get the Web Developer Tools. $.get("ajax.php", {case: caseNr,

您的问题出现在IE8的第43行karlsten.js上,因此您可能希望在IE8上调试它,如果可能,或者获取Web Developer Tools。 $ .get(“ajax.php”,{case:caseNr,

But, someone just submitted this before I did, with a good answer. :)

但是,有人在我做之前提交了这个,并给出了一个很好的答案。 :)

#1


here is your problem:

这是你的问题:

$.get("ajax.php", {case: caseNr, picturenr: picNr, pictureinfo: true}, function(data){

case is a reserved word. When using hashes, always make keys be strings, and you will never get yourself in to trouble

case是保留字。使用哈希时,总是让键成为字符串,你永远不会陷入麻烦

$.get("ajax.php", {"case": caseNr, "picturenr": picNr, "pictureinfo": true}, function(data){

#2


Your problem is on line 43, karlsten.js, on IE8, so you may want to debug it on IE8, if possible, or get the Web Developer Tools. $.get("ajax.php", {case: caseNr,

您的问题出现在IE8的第43行karlsten.js上,因此您可能希望在IE8上调试它,如果可能,或者获取Web Developer Tools。 $ .get(“ajax.php”,{case:caseNr,

But, someone just submitted this before I did, with a good answer. :)

但是,有人在我做之前提交了这个,并给出了一个很好的答案。 :)