Jump to content

IE style attribute problems


asylum

Recommended Posts

Hello everyone, I'm preparing to go "live" with my website and I need to make sure it works in IE but I've been informed by a friend that the menu doesn't slide because of some error. So I would like to knw what I'm doing wrong. Undoubtedly it is related to the way I am attempting to get the style properties so here's that piece of code:

function getStyleT(obj,s){        if(document.all)                return obj.style.getPropertyValue(s);        else                return document.defaultView.getComputedStyle(obj,"").getPropertyValue(s);}

It works fine in FF obviously :) so I just need some people with IE know-how to help me out here. The website is unnaturalfusion.com

Link to comment
Share on other sites

It works fine in FF obviously
Wow :) I just tried it in FF and it seemed to stutter a little then fired out :) I found it difficult to control, just though i'd let you know.I found a good cross browser of this a while backhttp://www.faqts.com/knowledge_base/view.phtml/aid/7157for IE it returns:return eval(objName + ".currentStyle." + property);But i think there's more to it than that.
Link to comment
Share on other sites

Well if you hold your mouse still over it then it wouldn't do that :) And it's just a prototype menu that I capriciously included.I'm still having problems with IE4+ (aka IE6). For some reason the offsetLeft property isn't working and the obj.getAttribute("id") returns null (I know it doesn't have an id now but I added one and it still said that).If anyone can figure this out I would greatly appreciate it, though I know that's not much incentive :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...