MediaWiki:Resources/landingpage.js: Difference between revisions

From Donate
Jump to navigation Jump to search
Content deleted Content added
Pgehres (WMF) (talk | contribs)
No edit summary
blank - all moved to MediaWiki:Common.js (not deleting so history stays visible)
Tag: Blanking
 
(48 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<html>
<script type="text/javascript">
$( document ).ready( function () {
// Disable submitting form with return key
$( 'form' ).bind( 'keypress', function(e) {
var code = ( e.keyCode ? e.keyCode : e.which );
if ( code == 13 ) return false;
} );

$("#p-logo a").attr("href", "#");
$("#p-logo a").attr("title", "");
} );

function getQuerystring( key ) {
key = key.replace( /[\[]/, '\\\[' ).replace( /[\]]/, '\\\]' );
var regex = new RegExp( '[\\?&]' + key + '=([a-zA-Z0-9\_\-]*)' );
var qs = regex.exec( window.location.search );
return qs == null ? '' : qs[1];
}

</script>
</html>

Latest revision as of 18:08, 27 March 2019