Skip to content

Instantly share code, notes, and snippets.

@swalke16
Created August 2, 2010 15:27
Show Gist options
  • Save swalke16/504810 to your computer and use it in GitHub Desktop.
Save swalke16/504810 to your computer and use it in GitHub Desktop.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title></title>
<link rel="stylesheet" href="css/jquery-ui-1.8.2.custom.css" />
<script type="text/javascript" src="jquery-1.4.2.js"></script>
<script type="text/javascript" src="jquery-ui-1.8.2.custom.min.js"></script>
<script type="text/javascript">
$(function(){
$("#btn").button({
icons: { primary: 'ui-icon-play' }
})
.click(function(){alert('hi')});
$('#text').change(function(){
$("#btn").button('option', 'label', 'Changed'); //TODO: this prevents the button click from actually happening in chrome...
});
});
</script>
</head>
<body>
<button id="btn">Initial</button>
<input id='text' type="text" />
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment