CoreFiles by mySites.guru
users.js21 lines, 845 bytes, from wordpress-2.2.zip
Raw History Compare with 2.1.3
md5
ef8872688bcab72a712e681b5bdd0c36
sha1
159872770b0561f04d6fe5ac1ed5e15661feba2e
sha256
1d6adbd03fd1bf4a7d5faa53253c06807f7a4bf3899da53a86c9c0f9310cb7c6
addLoadEvent(function() {
	theListEls = document.getElementsByTagName('tbody');
	theUserLists = new Array();
	for ( var l = 0; l < theListEls.length; l++ ) {
		if ( theListEls[l].id )
			theUserLists[theListEls[l].id] = new listMan(theListEls[l].id);
	}
	addUserInputs = document.getElementById('adduser').getElementsByTagName('input');
	for ( var i = 0; i < addUserInputs.length; i++ ) {
		addUserInputs[i].onkeypress = function(e) { return killSubmit('addUserSubmit();', e); }
	}
	document.getElementById('addusersub').onclick = function(e) { return killSubmit('addUserSubmit();', e); }
}
);

function addUserSubmit() {
	var roleEl = document.getElementById('role');
	var role = roleEl.options[roleEl.selectedIndex].value;
	if ( !theUserLists['role-' + role] ) return true;
	return theUserLists['role-' + role].ajaxAdder('user', 'adduser');
}

The same content is in 23 releases, WordPress 2.1-beta1 to 2.2.3. See them all, or every version of this file.