PDA

View Full Version : Animated Collapsible DIV v2.4 shrink when close and go to main page



Dahls
05-23-2013, 05:33 PM
1) Script Title:
Animated Collapsible DIV v2.4
2) Script URL (on DD):
http://www.dynamicdrive.com/dynamicindex17/animatedcollapse.htm
3) Describe problem:

no problem great code :) thank you, system works fine

i just wish for some extra function
my problem is i use it with a form for get new password . when form is ended it says mail with new password is send, then if user refresh the page, firefox pop up some info about there is a running script (my password script) and if they click ok it sends new password and keep saying script is running until main page is loaded,

so i like a function so when click the link it shrink the div and go to the main page index.php

ddadmin
05-24-2013, 10:44 AM
The script does support dynamically showing or hiding a collapsible DIV. See the section "Available functions" on the script page (http://www.dynamicdrive.com/dynamicindex17/animatedcollapse.htm) for documentation on that. With that said, the code to collapse a DIV and redirect to another page after x seconds might look something like:


animatedcollapse.hide('jason')
setTimeout("window.location='http://www.google.com'", 600)

Where 600 = 600 milliseconds, and should coincide roughly with the time it takes to collapse the DIV (default is 500 milliseconds, see "speed" attribute when initializing the script).