<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    <font face="Georgia">Hmmm.... try it with something other than a
      button. I think the clicking behavior is being pre-empted by the
      button itself.<br>
      <br>
      Cheers,<br>
      Bob<br>
    </font><br>
    On 10/22/10 5:52 PM, Thomas McCune wrote:
    <blockquote cite="mid:80E4B523B32C4ECD9EBA7675AA12E1B6@mccune.com"
      type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <meta name="GENERATOR" content="MSHTML 8.00.6001.18975">
      <style></style>
      <div><font face="Arial" size="2">In HTML it is possible to create
          a button in a form and cause Javascript to execute</font></div>
      <div><font face="Arial" size="2">using onClick. For example, the
          following form causes the JavaScript alert function</font></div>
      <div><font face="Arial" size="2">to be executed when the button is
          clicked.</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">&lt;form name="myForm"&gt;<br>
          Name: &lt;input type="text"<br>
          onkeyup="ajaxFunction('Hello');" name="username" /&gt;<br>
          Time: &lt;input type="text" name="time" /&gt;&lt;br&gt;<br>
          &lt;input type=BUTTON onClick="alert('GoodBye');"
          value="GoodBye" /&gt;<br>
          &lt;/form&gt;</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">In Seaside, I have tried to
          achieve the same without success with the</font></div>
      <div><font face="Arial" size="2">following button definition:</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">renderDoItButtonOn: html</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">&nbsp;html button with: 'Doit';<br>
          &nbsp;&nbsp;onClick: 'alert("GoodBye");'.</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">The page refreshes but the
          JavaScript does not appear to execute. Is there a way</font></div>
      <div><font face="Arial" size="2">to accomplish this? I have tested
          onKeyUp: and it does execute the string as</font></div>
      <div><font face="Arial" size="2">JavaScript just as I expected.</font></div>
      <div>&nbsp;</div>
      <div><font face="Arial" size="2">Thank you</font></div>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
seaside mailing list
<a class="moz-txt-link-abbreviated" href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a>
<a class="moz-txt-link-freetext" href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a>
</pre>
    </blockquote>
  </body>
</html>