[Javascript] Strange margins with scriptaculous

Frank Arensmeier frank.arensmeier at nikehydraulics.se
Mon Jan 8 08:59:56 CST 2007


Well, actually, there was nothing wrong/wired with neither the divs,  
the script nor the CSS. When visiting the page from our Intranet,  
users are able to print the downloadable pdf docs directly from that  
page. This is done by hitting a little printer icon to the right form  
the download link. This icon is right floated. And it seems that the  
browsers mentioned have some difficulties to calculate the accurate  
hight of the div. Because I switched off this function on my test  
box, everything was as ok. Since I am the only one here using Safari,  
I thought it was no big deal (MS Explorer has no problems).

Setting the bottom margin to -10px (icon is 10x10px) to the printer  
icon, fixed the "ghost" margin at the bottom - margin was 0px before.

However, as mentioned before, there is still one more problem which I  
haven't found a solution for yet. Hitting the show/hide triangle when  
the div is not entirely expanded, the div content will overlap with  
the following div when sliding down again. Once more, I was able to  
observe this behaviour in Safari, Firefox and Opera only. MS Explorer  
- no problem. Those browsers do not seem to calculate the height for  
the entire div content but will keep the height for the partly  
expanded div.

//frank

8 jan 2007 kl. 14.00 skrev John Warner:

> Could you share with the archive in case this happens to someone  
> else in the future?
>
>
> John Warner
> -----Original Message-----
> From: javascript-bounces at LaTech.edu [mailto:javascript- 
> bounces at LaTech.edu] On Behalf Of Frank Arensmeier
> Sent: Monday, January 08, 2007 5:49 AM
> To: [JavaScript List]
> Subject: Re: [Javascript] Strange margins with scriptaculous
>
> Never mind. I found the reason.
>
> /frank
>
> 8 jan 2007 kl. 11.34 skrev Frank Arensmeier:
>
>> Hello.
>>
>> I apologize if my question is more related to CSS than it is to  
>> Javascript.
>>
>> Yesterday I updated one of my pages with some effects from the  
>> scriptaculous lib. Now, I have some strange problems when showing  
>> divs. When toggling an effect, some divs have a strange bottom  
>> margin. Have a look at:
>>
>> http://www.nikehydraulics.se/downloads/leaflets_gb.php
>>
>> Click on one of the categories e.g. "Automotive tools". When the  
>> div slides down, it has a really annoying margin at the bottom  
>> (the larger the content, the larger the bottom margin). When the  
>> div is expanded, the divs below are pushed into the correct  
>> positions.  I might also say that I have noticed this behavior in  
>> Safari 2.0.4, Firefox 2 and Opera 9.02 (all Mac versions). MS  
>> Explorer 6 on PC works as aspected.
>>
>> Besides that, when "canceling" an effect by hitting the show/hide  
>> triangle once more, Safari (at least) will not push the divs below  
>> to the proper positions. Instead, divs below will overlap with the  
>> expanded div.
>>
>> The exact same page on my local testing machine, behaves ok.
>>
>> Hope you get what I mean.
>>
>> Any ideas? I was not able to get any hints on the scriptaculous site.
>>
>> /frank
>>
>> _______________________________________________
>> Javascript mailing list
>> Javascript at LaTech.edu
>> https://lists.LaTech.edu/mailman/listinfo/javascript
>
> --
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.5.432 / Virus Database: 268.16.7/619 - Release Date:  
> 1/7/2007 6:29 PM
>
>
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> https://lists.LaTech.edu/mailman/listinfo/javascript

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.evolt.org/pipermail/javascript/attachments/20070108/e7925e0b/attachment.htm>


More information about the Javascript mailing list