MediaWiki:Common.js: Difference between revisions

From BibleVerseWiki
No edit summary
No edit summary
Line 4: Line 4:
window.addEventListener('keydown',function(e)
window.addEventListener('keydown',function(e)
{
{
console.log($("[name=search]").val());
     // e = e || window.event;
     // e = e || window.event;
     // var target = e.target || e.srcElement;
     // var target = e.target || e.srcElement;

Revision as of 04:16, 29 April 2024

/* Any JavaScript here will be loaded for all users on every page load. */


window.addEventListener('keydown',function(e)
{
	console.log($("[name=search]").val());
    // e = e || window.event;
    // var target = e.target || e.srcElement;
    // console.log('window noticed you clicked something');
    // console.log(target);//<-- this is the element that was clicked
},true);//<-- we'll get to the false in a minute