Code <!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">
</script>
<script>
$(function(){
$("#in1").focus(function(){
$(this).css("background","red");
});
$("#in1").blur(function(){
$(this).css("background","green");
});
});
</script>
<style>
#in1{
width:50%;
color:white;
}
</style>
</head>
<body>
<input id="in1" accesskey="C" placeholder="Focus tôi => Tôi red. Blur tôi => Tôi green">
</body>
</html>