SEDE User ID Autofiller v0.1
This commit is contained in:
parent
55e005b5ea
commit
913a671ef3
1 changed files with 7 additions and 2 deletions
|
@ -7,6 +7,13 @@
|
||||||
// @author Glorfindel
|
// @author Glorfindel
|
||||||
// @version 0.1
|
// @version 0.1
|
||||||
// @match *://data.stackexchange.com/*/query/*
|
// @match *://data.stackexchange.com/*/query/*
|
||||||
|
// @connect *.stackexchange.com
|
||||||
|
// @connect *.stackoverflow.com
|
||||||
|
// @connect *.superuser.com
|
||||||
|
// @connect *.serverfault.com
|
||||||
|
// @connect *.askubuntu.com
|
||||||
|
// @connect *.mathoverflow.net
|
||||||
|
// @connect stackapps.com
|
||||||
// @grant GM_xmlhttpRequest
|
// @grant GM_xmlhttpRequest
|
||||||
// @grant GM.xmlHttpRequest
|
// @grant GM.xmlHttpRequest
|
||||||
// ==/UserScript==
|
// ==/UserScript==
|
||||||
|
@ -27,7 +34,6 @@
|
||||||
url: 'https://stackexchange.com/users/current',
|
url: 'https://stackexchange.com/users/current',
|
||||||
onload: function (data) {
|
onload: function (data) {
|
||||||
let matches = /\/users\/(\d+)\//g.exec(data.finalUrl);
|
let matches = /\/users\/(\d+)\//g.exec(data.finalUrl);
|
||||||
// Fill input field
|
|
||||||
input.val(matches[1]);
|
input.val(matches[1]);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -60,7 +66,6 @@
|
||||||
url: 'https://' + site + '/users/current',
|
url: 'https://' + site + '/users/current',
|
||||||
onload: function (data) {
|
onload: function (data) {
|
||||||
let matches = /\/users\/(\d+)\//g.exec(data.finalUrl);
|
let matches = /\/users\/(\d+)\//g.exec(data.finalUrl);
|
||||||
// Fill input field
|
|
||||||
input.val(matches[1]);
|
input.val(matches[1]);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue