469,313 Members | 2,254 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,313 developers. It's quick & easy.

onkeyup and onblur conflict if used in the same tag

hi everyone,

i just want to share my experience....,that never use alert when u are calling 2 functions in the same tag using onkeyup or onblur events,........becoz wht ever function u r going to call in onkeyup,,,if there is any alert msg is there then...first the onblur function is called due to alert the focus is coming out of the of the tag and this will automatically call the onblur function.....


Alind
Oct 6 '07 #1
3 2109
acoder
16,027 Expert Mod 8TB
Welcome to TSDN!

Instead of an alert, you can use a span/div to display your message. This can be less annoying and shouldn't remove the focus.
Oct 6 '07 #2
Welcome to TSDN!

Instead of an alert, you can use a span/div to display your message. This can be less annoying and shouldn't remove the focus.

now i am doing that only using span to display err....., neway thanks for replying...

but my prob.. is that now

when i am re-assigning the focus..., then the error msg is gone...,

so it just display an error msg for some millisecounds or u can say that...

no one can see that msg....,

here a brief description of wht i am doing

I am checking the length of a field on blurr, but i want that if the field length is less than some minimum length..it should show some msg in span..

but...without losing focus...,as on blur means focus is lost....
so everything works fine...., but that error msg to display on blurr is gone....
Oct 8 '07 #3
dmjpro
2,476 2GB
now i am doing that only using span to display err....., neway thanks for replying...

but my prob.. is that now

when i am re-assigning the focus..., then the error msg is gone...,

so it just display an error msg for some millisecounds or u can say that...

no one can see that msg....,

here a brief description of wht i am doing

I am checking the length of a field on blurr, but i want that if the field length is less than some minimum length..it should show some msg in span..

but...without losing focus...,as on blur means focus is lost....
so everything works fine...., but that error msg to display on blurr is gone....

Post your Code here :-)
And let the experts to analyze .

Debasis Jana
Oct 8 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

By using this site, you agree to our Privacy Policy and Terms of Use.