Changes
Jump to navigation
Jump to search
← Older edit
Newer edit →
MediaWiki:Common.js
(view source)
Revision as of 15:05, 18 April 2018
371 bytes removed
,
15:05, 18 April 2018
no edit summary
Line 11:
Line 11:
var apiURL = 'https://wiki.gccollab.ca/api.php';
var apiURL = 'https://wiki.gccollab.ca/api.php';
−
var originURL = 'https://wiki.gccollab.ca';
−
−
$.ajax({
−
url: apiURL,
−
data: {
−
action: 'query',
−
meta: 'userinfo',
−
format: 'json',
−
origin: originURL
−
},
−
xhrFields: {
−
withCredentials: true
−
},
−
dataType: 'json'
−
}).done(function (data){
−
console.log(data);
−
});
−
$.ajax({
$.ajax({
Line 35:
Line 17:
action: 'query',
action: 'query',
meta: 'tokens',
meta: 'tokens',
−
format: 'json'
,
+
format: 'json'
−
origin: originURL
},
},
xhrFields: {
xhrFields: {
Line 45:
Line 26:
console.log(data);
console.log(data);
$.ajax({
$.ajax({
−
url: apiURL
+ '?origin=' + originURL
,
+
url: apiURL,
method: 'POST',
method: 'POST',
data: {
data: {
Mark.wooff
Bureaucrats
,
Administrators
55
edits
Navigation menu
GC
wiki
Personal tools
English
Log in
Namespaces
Message
Discussion
Variants
Views
Read
View source
View history
More
Search
Navigation
Main Page
Browse categories
Random page
Help
Actions/Tools
Special pages
Tools
Printable version
GCaccount
GCcollab
GCmessage