User:The last username left/utils.js

// http://www.netlobo.com/url_query_string_javascript.html function getParam(name) { name = name.replace(/[\[]/, '\\\[').replace(/[\]]/, '\\\]'); var regex = new RegExp('[\\?&]' + name + '=([^&#]*)'); var results = regex.exec(window.location.href); if (results == null) return ''; else return decodeURIComponent(results[1].replace(/\+/g, '%20')); }