View Full Version : Javascript 2 functions onClick event
avaloncm
08-20-2004, 11:05 AM
I need to run 2 separate functions on the onClick event. Basically I need to run the same function twice with different parameters. Is there a way to do this with the onClick event?
Thanks!
Goldilocks
08-20-2004, 11:10 AM
Have you tried something like:
onClick="function1(paramater1); function1(paramater2);"
I haven't done that before so don't know if it's that simple but I don't see why not.
avaloncm
08-20-2004, 11:22 AM
Thanks!
onClick="function1(paramater1); function1(paramater2);" works.
I was trying
onClick="function1(paramater1)"; "function1(paramater2);"
Theoretically, couldn't you also do
onmousedown="function(param);" onmouseup="function(param);"
?
vBulletin® v3.6.7, Copyright ©2000-2009, Jelsoft Enterprises Ltd.