jQuery
1
Code Link 1 Source Documentation:
$("#id")
.click(function(){
$(this).css({ background: "red" });
})
.mouseout(function(){
$(this).css({ background: "blue" });
});
MooTools
1
Code Link 1 Source Documentation:
$("id").addEvents({
"click": function(){
this.setStyle("background", "red");
},
"mouseout": function(){
this.setStyle("background", "blue");
}
});
The Dojo Toolkit
1
Code Link 1 Source Documentation:
dojo.connect(dojo.byId("id"), "click", function(){
dojo.style(this, "background", "red");
});

dojo.connect(dojo.byId("id"), "onmouseout", function(){
dojo.style(this, "background", "blue");
});
Prototype / Script.aculo.us
1
Code Link 1 Source Documentation:
$("id").observe("click", function(){
this.setStyle({ "background": "red" });
});

$("id").observe("mouseout", function(){
this.setStyle({ "background": "blue" });
});
Ext JS
1
Code Link 1 Source Documentation:
Ext.get("id")
.on("click", function(){
this.setStyle("background", "red");
})
.on("mouseout", function(){
this.setStyle("background", "blue");
});
Adobe Spry
1
Code Link 1 Source Documentation:
Spry.$$("#id")
.addEventListener("click", function(){
Spry.$$("#id").setStyle("background: red;");
}, false)
.addEventListener("mouseout", function(){
Spry.$$("#id").setStyle("background: blue;");
}, false);
BBC Glow
1
Code Link 1 Source Documentation:
glow.events.addListener("#id", "click", function(){
glow.dom.get(this).css("background", "red");
});

glow.events.addListener("#id", "mouseout", function(){
glow.dom.get(this).css("background", "blue");
});
Yahoo! UI Library
1
Code Link 1 Source Documentation:
Y.one("#id").on({
click: function(e) {
this.setStyle("background", "red");
},
mouseout: function(e) {
this.setStyle("background", "blue");
}
});

 Matthias Schütz - Media Designer / Web Designer / Developer / Freelancer