Jump to content

User:Ocaasi/TWAcontents.js

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Ocaasi (talk | contribs) at 00:23, 5 July 2013 (comment out for now). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
/*
var requestData = {action:"edit", title: "User:"+mw.config.get("wgUserName"), appendtext: "Hello, World!", summary: "this is an edit summary", token:mw.user.tokens.get("editToken")};
$.post(mw.config.get("wgScriptPath")+"/api.php", requestData, function(responseData)
{
    //Whatever you want to do *after* the edit is posted goes here. For example:
    alert("posted successfully!");
});

*/