|
ActiveX warning problem
I've been doing webpages for some time now, but never got too much into Javascripting, I'm doing a webpage now that uses a couple of simple functions to toggle images and displays.
The code of one of the functions is the following:
function toggle(e) {
targetid = e.id + "d";
targetid2 = e.id + "i";
target = document.all(targetid);
target2 = document.all(targetid2);
if (target.style.display == "none")
{
target.style.display = "";
target2.src="img/visible.jpg";
}
else
{
target.style.display = "none";
target2.src="img/hidden.jpg";
}
}
As you can see it's pretty simple. We have an object (text, img, td.. whatever) with an id, and when pressed, it changes the id+d display attribute to none or null and changes the images of the id+i image.
The script works fine, but the question is regarding to using it under IE, everytime I load the page I get this annoying ACTIVE X warning saying that some contents may be insecure... and I don't know why, since my script doesn't do anything extraordinary.
Even if I just have the link to the .js file without upload the .js file, it will give me the error just because I'm declaring a javascript function, even if I don't use it.
How can I get rid of the warning. I've been to this page that also declares a function, much more complex than mine <script src="../../jslibs/locvar.js" type="text/javascript" language="javascript1.2"></script> and I don't get the warning. Why ???
Any help would be greatly appreciated.
If you need more info I could comment a little bit more and give more specifics or links to the actual pages.
Thank you.
|