You can just use the fadeOut and fadeIn methods to animate just the opacity:

$('#mydiv').fadeOut().fadeIn().fadeOut().fadeIn();

You could loop a set number of times with something like this:

var blinkCount = 2*2;// two blinks, 4*2 for four blinks
do {
   $('#mydiv')['fade'+(blinkCount%2==0?'Out':'In')]('slow');
} while (--blinkCount);

--
Brandon Aaron


On 4/23/07, Alexandre Plennevaux <[EMAIL PROTECTED]> wrote:


no it does not work: it seems show() / hide() works on the width, height, or
opacity. but then i guess i could try to build this effect by using a
timeout and display:none / auto or something like that....

 ________________________________
 From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Josh Nathanson
Sent: lundi 23 avril 2007 20:42
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Blink effect



How about callback = function() {
$("#mydiv").hide().show().hide().show()
}

-- Josh

----- Original Message -----
From: Alexandre Plennevaux
To: jquery-en@googlegroups.com
Sent: Monday, April 23, 2007 1:27 PM
Subject: [jQuery] Blink effect


hi,

i've been playing with the effects built in jquery and had a lot of fun
playing with such flexibility. However, i could not achieve what i wanted:
having an element blink twice when its html content get loaded via ajax. The
problem is the blinking of course, jquery has mad ajax so easy.
i was wondering if anyone succeeded in creating that special effect, that
would have something blink a certain number of times upon appearing ?

thank you very much!

alex


Alexandre Plennevaux - LAb[au] asbl.vzw / MediaRuimte
Lakensestraat/Rue de Laeken 104
B-1000 Brussel-Bruxelles-Brussels
Belgie-Belgique-Belgium

Tel:+32(0)2.219.65.55
Fax:+32(0)2.426.69.86
Mobile:+32(0)476.23.21.42
http://www.lab-au.com
http://www.mediaruimte.be

__________________________________________________________________________

The information in this e-mail is intended only for the addressee named
above.  If you are not that addressee, please note that any disclosure,
distribution or copying of this e-mail is prohibited.
Because e-mail can be electronically altered, the integrity of this
communication cannot be guaranteed.

__________________________________________________________________________



Ce message Envoi est certifié sans virus connu.
Analyse effectuée par AVG.
Version: 7.5.465 / Base de données virus: 269.5.9/773 - Date: 22/04/2007
20:18



Ce message Envoi est certifié sans virus connu.
 Analyse effectuée par AVG.
 Version: 7.5.465 / Base de données virus: 269.5.9/773 - Date: 22/04/2007
20:18

Reply via email to