View Full Version : Loading mechanics for collapsible divs script**

05-03-2008, 09:54 AM
1) Script Title: Animated Collapsible DIV -- animatedcollapse.js

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex17/animatedcollapse.htm

3) Describe problem:

Hey there. I'm quite the beginner at ajax and hardcore javascript, but I know my way around HTML and CSS pretty well.

The problem I am having with this script is the loading mechanics. You'll see that everytime the page is refreshed, the divs are loading in an expanded state, but then they collapse once everything is fully loaded. I have tried numerous different tweaks to get them to load in the collapsed state (i.e. no fixed height, persist set to true/false, adding/removing tables), but to no avail.

You can view the page here: http://360designstudio.net/Clients/countryclubbni/members.html

Just keep hitting refresh on Firefox or IE, and you'll see what I mean.

Any ideas? I'm open to all suggestions that you think could improve the loading functions of my page.

Thanks! :o

05-04-2008, 08:33 PM

07-05-2008, 01:53 AM
The code at the bottom of the script's description page says to add:

<div id="jason" style="width: 300px; background: #FFFFCC; display:none">
<b>Content inside DIV!</b>

to force the div to stay hidden. Don't know this will solve your problem, hopefully it does.

07-05-2008, 09:58 AM
Yep, adding an inline or global CSS that targets the elements in question with "display:none" should do it.