Skip to main content

Search and Top Navigation

Ticket #6242: webkit-button.html


File webkit-button.html, 0.8 KB (added by morozov, October 29, 2010 12:11PM UTC)

Demo

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <title>Test page</title>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
</head>
<body>
  <input type="text" value="input"/>
  <button>button</button>
  <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
  <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/jquery-ui.min.js"></script>
  <script>

  var $button = $("button").button().click(function() {
    alert("clicked");
  });

  $("input").blur(function() {
    $button.button("enable");
  });

  </script>
</body>
</html>

Download in other formats:

Original Format