...

View Full Version : JS acting different in FF and IE



atomicnuke
08-16-2005, 05:37 AM
I'm currently just throwing concepts together to learn techniques, which I will use to create a more original site. I had the js working here (http://www.ilovetaffy.com/testingphase/image.html). If you click the hide/unhide, the CSS class, which contains id's, expands and shrinks accordingly. Then I wanted to add a footer that stays glued to the bottom, to do this I had to group my layout and but it in a container (id). The footer works how it should in both browsers, but now the hide/unhide only works in IE. In IE it expands and the right div hides, in FF the div hides, but the content doesn't expand. Here is the link (http://www.ilovetaffy.com/testingphase/footeradjust.html) that is causing the problem. My JS code is in the source, the only thing that changed coding wise is the new container that surrounds everything but the footer. Not sure if it is a flaw in FF, because it works fine in IE. The weird thing is, in the JS code, if I change the 10 to a 0 in:
x.style.marginRight = (style2.display == "none") ? "10":"205px"; then both browsers behave accordingly, expanding it to the edge of the screen, but if I put it to 10 how I want it, only IE works. Is the new main container causing problems to js?

Single Paradox
08-16-2005, 05:58 AM
x.style.marginRight = (style2.display == "none") ? 10:205+"px";

atomicnuke
08-16-2005, 06:01 AM
Still didn't work, it was fine until the added container, but I know it has to be possible, IE of all things is working right.

atomicnuke
08-16-2005, 05:31 PM
Fixed it the resizing, now have to figure out why the foot moves, thanks.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum