'$ .fn' is null or not an object
Problem 1
Error: Microsoft JScript Runtime Error: "$ .fn" is null or not an object
Error area:
$.fn.apply=function(item,content,header){
$(".featureBox"+item).css('z-index', "1000");
$("img.featureBox" + item +"top").attr("src",basepath + "box-big-top.jpg");
$("img.featureBox" + item +"imgcut").attr("src",basepath + "box-big-img"+item+".jpg");
featureboxcont[item].attr("src",basepath + "box-big-cont.jpg");
$("img.featureBox" + item +"foot").attr("src",basepath + "box-big-bot2.jpg");
//$("#NoteModalDialog > #x-dlg-bd > #x-dlg-tab > #acc-ct")
$("#box"+item+"headtext > .h2div > h2").text(header);
$("#box"+item+"bottext").css({"top":"181px","width":"205px","font-size":"12px","color":"#ffffff","left":"10"});
$("#box"+item+"foottext").css({"top":footheight+"px","width":"215px","left":"20"});
$("#box"+item+"hidden").css({"display":"block"});
$("#box"+item+"bottext").text(content);
$("#box"+item+"headtext > .h2div > h2").removeClass("sIFR-replaced");
callsIFR();
}
Problem 2
Error: Microsoft JScript Runtime Error: "null" is null or is not an object
Error area:
$("#innerWrapper").addClass("js-version");
I am also using protoype.js on the page.
a source to share
If you are using jQuery and Prototype on the page, $.fn
it will most likely be undefined in the global scope. The only way to use jQuery and Prototype on the same page is to use jQuery.noConflict
and assign it a different symbol than $
that Prototype also uses.
a source to share
Why are you filing an expression in the declaration? apply is used to specify this by a method. usually you do something like this ...
var object1 = {X:"stuff"};
var $.fn = function () {
/* substitute your method here */
this.X = this.X || "default";
alert(this.X);
};
$.fn.apply(object1);
a source to share