Wikipedia:AutoEd/wikichecker.js

Revisi sejak 11 Mei 2018 20.53 oleh Argo Carpathians (bicara | kontrib) (Dari WP:EN.)
(beda) ← Revisi sebelumnya | Revisi terkini (beda) | Revisi selanjutnya → (beda)

//

var AutoEd_baseurl = 'http://wiki-indonesia.club/w/index.php?action=raw&ctype=text/javascript&title=Wikipedia:AutoEd/';
if (location.protocol === 'https:') {
  AutoEd_baseurl = 'https://wiki-indonesia.club/w/index.php?action=raw&ctype=text/javascript&title=Wikipedia:AutoEd/';
}

importScriptURI(AutoEd_baseurl + 'core.js'); //Imports the "framework" script needed to make this function

//Sets variable configuration
autoEdTag = "[[WP:CHECKWIKI|Pemeriksaan Wikipedia]] menggunakan [[WP:AutoEd|AutoEd]]"; //Supplies link to CHECKWIKI in summary
autoEdLinkName = "check"; //Changes the link name at the top of the page
autoEdLinkHover = "Jalankan AutoEd untuk Pemeriksaan Wikipedia"; //When user hovers over link
 
//Import individual modules for use
importScriptURI(AutoEd_baseurl + 'unicodify.js'); // autoEdUnicodify() converts HTML entities to WikiText
importScriptURI(AutoEd_baseurl + 'isbn.js'); // autoEdISBN() fixes ISBN syntax so that WikiMagic can work
importScriptURI(AutoEd_baseurl + 'wikilinks.js'); // autoEdWikilinks() simplifies and shortens wikilinks where appropriate
importScriptURI(AutoEd_baseurl + 'htmltowikitext.js'); // autoEdHTMLtoWikitext() converts HTML to wikitext
importScriptURI(AutoEd_baseurl + 'headlines.js'); // autoEdHeadlines() fixes common headline errors and renames some headers
importScriptURI(AutoEd_baseurl + 'unicodecontrolchars.js'); // autoEdUnicodeControlChars() converts HTML to wikitext
importScriptURI(AutoEd_baseurl + 'templates.js'); // autoEdTemplates() cleans up templates
importScriptURI(AutoEd_baseurl + 'tablestowikitext.js'); // autoEdTablestoWikitext() replaces HTML tables with wikitables
importScriptURI(AutoEd_baseurl + 'extrabreaks.js'); // autoEdExtraBreaks() removes extra BR tags
importScriptURI(AutoEd_baseurl + 'links.js'); // autoEdLinks() cleans up common link errors

function autoEdFunctions() { //Activates individual modules when "auto ed" tab is clicked
    var txt = document.editform.wpTextbox1;
    txt.value = autoEdUnicodify(txt.value);
    txt.value = autoEdISBN(txt.value);
    txt.value = autoEdWikilinks(txt.value);
    txt.value = autoEdHTMLtoWikitext(txt.value);
    txt.value = autoEdHeadlines(txt.value);
    txt.value = autoEdUnicodeControlChars(txt.value);
    txt.value = autoEdTemplates(txt.value);
    txt.value = autoEdTablestoWikitext(txt.value);
    txt.value = autoEdExtraBreaks(txt.value);
    txt.value = autoEdLinks(txt.value);
}

//