Sha256: 1b020eafe32d3cb65be58c649757c8494151449d484bd02b56ebc0e304dd02dc

Contents?: true

Size: 1.05 KB

Versions: 51

Compression:

Stored size: 1.05 KB

Contents

<htmL>
<head>
  <title>Prototype - Sample App</title>
  <script type="application/x-javascript" src="/prototype-1.6.0.3.js"></script>
</head>
<body>
  <div id="ajax-demo">
    <h2>AJAX Calculator</h2>
    <form id="calculator-form" action="#" method="post" onSubmit="return false;">
      <input id="calculator-expression" name="calculator-expression"/>
      <input type="submit" id="calculator-button" value="Compute" />
      <br/><br/>
      <div>Result: <input id="calculator-result" disabled /></div>
    </form>

    <script type="text/javascript" language="javascript">  
      Event.observe(window, 'load', function() {

        Event.observe('calculator-button', 'click', function (event) {
          new Ajax.Request('/compute', { 
              method: 'post', 
              parameters: $('calculator-form').serialize(true),
              onSuccess: function(transport) {
                $('calculator-result').value = transport.responseText;
              },
          });
          return false;
        });

      });
    </script>
  </div>

</body>
</html>

Version data entries

51 entries across 51 versions & 4 rubygems

Version Path
page-object-1.2.0 features/sample-app/public/prototype.html
page-object-1.1.1 features/sample-app/public/prototype.html
page_object-1.1.3 features/sample-app/public/prototype.html
page_object-1.1.2 features/sample-app/public/prototype.html
page_object-1.1.1 features/sample-app/public/prototype.html
page-object-1.1.0 features/sample-app/public/prototype.html
page-object-lds-0.0.14 features/sample-app/public/prototype.html
page-object-lds-0.0.13 features/sample-app/public/prototype.html
page-object-lds-0.0.12 features/sample-app/public/prototype.html
page-object-lds-0.0.11 features/sample-app/public/prototype.html
page-object-lds-0.0.1 features/sample-app/public/prototype.html
page-object-1.0.3 features/sample-app/public/prototype.html
meeane-page-object-0.1.11 features/sample-app/public/prototype.html
page-object-1.0.2 features/sample-app/public/prototype.html
page-object-1.0.1 features/sample-app/public/prototype.html
page-object-1.0 features/sample-app/public/prototype.html
page-object-0.9.8 features/sample-app/public/prototype.html
page-object-0.9.7 features/sample-app/public/prototype.html
page-object-0.9.6 features/sample-app/public/prototype.html
page-object-0.9.5 features/sample-app/public/prototype.html