Hi,
Problem mit setTimeout ist, dass die Funktion f_1 weiterläuft bevor setTimeout("f_2") ausgeführt wird.
Natuerlich.
setTimeput macht nur eine kleine Notiz in den Kalaendar, "zum Zeitpunkt X Aktion Y ausfuehren".
Nach dem schreiben dieser Notiz laueft das restliche Script weiter.
Gibts ne bessere Funtion als setTimeout oder kann ich mein dimm-Problem anderst lösen?
Felix' Artikel Fader-Framework - kleiner Lehrgang zum vernünftigen Schreiben eines JavaScripts hilft beim Einstieg in die verwendeten Techniken.
MfG ChrisB
--
„This is the author's opinion, not necessarily that of Starbucks.“
„This is the author's opinion, not necessarily that of Starbucks.“