Template:Form-template/Form-template-default: Difference between revisions

From Donate
Jump to navigation Jump to search
Content deleted Content added
Pgehres (WMF) (talk | contribs)
oops
Pgehres (WMF) (talk | contribs)
moved getQuerystring to MediaWiki:Resources/landingpage.js
Line 2: Line 2:
<html>
<html>
<script type="text/javascript">
<script type="text/javascript">

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];
}


//Should this be here?
//Should this be here?

Revision as of 18:44, 22 March 2012