1.

Example of JQuery focus event on textbox

Answer»

Below is the example for JQuery to change COLOUR of textbox on foucs on it.First we take a html CONTROL and do jquery on it.

< input id="Inputtxt" type="text" />

JQuery script for changing BACKGROUND COLOR on receiving focus

< script language="javascript" type="text/javascript">
$(document).ready(function () {

$("#txtInput1").focus(
function (EVENT) {
$("#Inputtxt").css("background-color", "Yellow");
}
);
});



Discussion

No Comment Found