or you can just call both functions from the onClick event like so:
onclick="doOne(); doTwo()"
-----Original Message-----
From: David Baskin [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 22, 2001 9:27 AM
To: CF-Talk
Subject: RE: Two functions with a single onClick?
Les, here's some code for you. HTH.
david
--------------------->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Untitled</title>
<script language="JavaScript">
<!--
function doTwo(){
doFirst();
doSecond();
}
function doFirst(){
alert("I'm the first function");
}
function doSecond(){
alert("I'm the second function");
}
// -->
</script>
</head>
<body>
<form name="myForm">
run two javascript functions by clicking on this button: <input
type="Button" name="clickMe" onclick="doTwo();" value=" Click Me! ">
</form>
</body>
</html>
-----Original Message-----
From: Les Irvin [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 21, 2001 2:58 PM
To: CF-Talk
Subject: Two functions with a single onClick?
Can more than one javascript function be performed with a single
onClick? If so, how would it be written?
Thanks,
Les
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists