SoFunction
Updated on 2025-03-10

JS gets the regular function of the specified value in the URL


<script type="text/javascript">
= function(name){
var reg = new RegExp('(^|\\?|&)'+name+'=([^&]*|$)'), url = (/&amp;/g, '&'), r = (reg);
return r === null ? null : unescape(r[2]);
}
var str = '/msgrd?v=3&amp;uin=1438344583&amp;site=qq&amp;menu=yes';
alert(('uin'));
</script>