Created
February 2, 2011 05:44
-
-
Save honda0510/807300 to your computer and use it in GitHub Desktop.
複数のコントロールに同じイベントを設定する、hta + jQuery のサンプル
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | |
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> | |
<title>hta + jQuery sample</title> | |
</head> | |
<body> | |
<button>ELMO</button><br /> | |
<button>BIG BIRD</button><br /> | |
<button>COOKIE MONSTER</button><br /> | |
<script type="text/JavaScript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script> | |
<script type="text/JavaScript"> | |
(function($) { | |
$(window).bind('load', | |
function(e) { | |
window.resizeTo(300, 150); | |
} | |
); | |
$('button').click( | |
function(e) { | |
alert(this.value); | |
} | |
); | |
})(jQuery); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment