Please support wikEd by helping to fix the following browser and MediaWiki issues.
wikEd |
---|
Installation |
wikEd diff |
Program code |
Project |
Gadgets |
|
Translations |
|
wikEd is a full-featured edit page text editor for regular to advanced users on Wikipedia and other MediaWikis. wikEd features syntax highlighting, reference, template, and code folding, on-page Show preview and Show changes, and advanced search and replace functions. Please check the wikEd help page for details. wikEd works under all web browsers except Internet Explorer.
How to install wikEd (choose one option):
Type | Scope | Installation | Remarks |
---|---|---|---|
Gadget | Local Wikipedia language or wiki only | Select wikEd under Gadgets in your wiki preferences | The easiest option on the English Wikipedia. Not available on all wikis. |
User script | Local Wikipedia language or wiki only | Paste a small code snippet to your User:YourUsername/common.js page | |
Every Wikipedia language and MediaWiki installation | Paste a small code snippet to your meta:User:YourUsername/global.js page | ||
Site wide | Local wiki only | A wiki administrator has to paste a code snippet to the MediaWiki:Common.js page | Site wide installation for all users |
Greasemonkey/Tampermonkey | Every Wikipedia language and MediaWiki installation | Install the Greasemonkey/Tampermonkey add-on for your browser, then install wikEd by clicking here | Also works for anonymous users that are not logged in |
See wikEd installation page for more details. That page also explains how to install wikEd on non-Wikipedia wikis and on wikis without internet connection and how to create a wikEd gadget.
Simply check wikEd under the Gadget section in your Wikipedia preferences (or use one of the other installation methods from above).
Check the wikEd help page for a description of all buttons. For a local installation as a Greasemonkey user script see below.
For more information, see below or check the wikEd installation page.
See also the wikEd help page for a description of all buttons and functions. wikEd adds the following functions as buttons above the edit textarea:
See wikEd international for translations of wikEd and how to install them. wikEd has been translated into Arabic, Chinese (simplified), Chinese (traditional), Croatian, Czech, Dutch, Esperanto, Finnish, French, Galician, German, Hebrew, Hungarian, Italian, Japanese, Korean, Kazakh, Lower Sorbian, Malay, Norwegian, New Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, Sicilian, Slovak, Slovenian, Spanish, Swedish, Turkish, Upper Sorbian, and Vietnamese. Detailed instructions on creating new translations can also be found on the wikEd international page.
If you're on Wikipedia, paste the following text to your user page:
{{User:Cacycle/wikEd userbox}}
to get this userbox:
This user edits with the gadget wikEd. |
Check who is using this box.
wikEd works under Firefox, SeaMonkey, Safari, WebKit, Google Chrome, Opera (version 15 and higher) but not yet under the currently not standards-compatible Internet Explorer.
wikEd works with all native MediaWiki skins and most of their derivatives. Other supported skins include:
In general, wikEd is incompatible with scripts, add-ons, or extensions that rely on or change the standard text edit box. The reason is that wikEd replaces the normal text area with its own separate rich-text iframe. Many of these scripts will still work if wikEd is temporarily turned off by pressing the button, making the changes, and re-enabling wikEd. It is possible to make scripts compatible with wikEd (see below).
This is a short and incomplete list of scripts and gadgets that are compatible with wikEd:
This is a short and incomplete list of scripts and gadgets that are not compatible with wikEd:
The wikEd edit box is a rich-text iframe while the standard edit box is a textarea with the id wpTextbox1. Nevertheless, developers can make their script compatible with wikEd by copying the text from the wikEd iframe to the standard textbox before making their changes and then copying the content back to the iframe. The following code is cross-browser compatible and wikEd-independent:
// copy wikEd (/info/en/?search=User:Cacycle/wikEd.js) frame to wpTextbox1 textarea
if (typeof(window.wikEd.useWikEd) != 'undefined') {
if (window.wikEd.useWikEd == true) {
wikEd.UpdateTextarea();
}
}
// make the changes to the classic wpTextbox1 textarea //
// copy wpTextbox1 textarea back to wikEd frame
if (typeof(window.wikEd.useWikEd) != 'undefined') {
if (window.wikEd.useWikEd == true) {
wikEd.UpdateFrame();
}
}
A more sophisticated way to apply local changes similar to custom button handlers is shown below. The example implements a "<div>...</div>" add or remove function around selected text:
// this example code adds or removes div tags around the selected text
function TestHandler(obj) {
// select the appropriate text change target (whole, selection, cursor, focusWord, focusLine, selectionWord, or selectionLine)
// focus... is the text under the cursor; ...Word and ...Line extend the target to the start/end of the word or line
wikEd.GetText(obj, 'selection, cursor');
if (obj.selection.plain != '') {
obj.changed = obj.selection;
}
else {
obj.changed = obj.cursor;
}
// make your changes to the plain target text in obj.changed.plain
// remove the previously added formatting
if ( /&lt;div&gt;(.*?)&lt;\/div&gt;/i.test(obj.changed.plain) ) {
obj.changed.plain = obj.changed.plain.replace(/&lt;div&gt;(.*?)&lt;\/div&gt;/gi, '$1');
}
// add the text formatting
else {
obj.changed.plain = '&lt;div&gt;' + obj.changed.plain + '&lt;/div&gt;';
obj.changed.plain = obj.changed.plain.replace(/(&lt;div&gt;)( *)(.*?)( *)(&lt;\/div&gt;)/, '$2$1$3$5$4');
}
// keep the changed text selected
obj.changed.keepSel = true;
// return to wikEd.EditButton() to apply changes
return;
}
if (typeof(window.wikEd.useWikEd) != 'undefined') {
wikEd.EditButton(null, null, null, TestHandler);
}
You can also add your custom functions to hooks that are executed on events such as wikEd setup, wikEd turned on or off, and classic textarea or wikEd frame turned on. It is also possible to directly apply changes to the wikEd edit frame, please see the wikEd development page.
This section focuses on getting wikEd to work. For other problems see the wikEd help page.
You have followed the installation instructions above, but the wikEd logo is not displayed on top of the pages next to the log out link and the wikEd buttons do not appear on edit pages. Please try the following:
Every wikEd project page has a navigation box on top. You can add this template to an English Wikipedia page by adding the following code on top of the page text:
{{User:Cacycle/wikEd_template}}
The following code can be used for wikEd navigation boxes and templates on non-Wikipedia sites and non-English Wikipedia pages. The box uses external html links. If you are not on Wikipedia or another Wikimedia site like Wiktionary or Wikinews, then you have to upload the logo WikEd_logo64x64.gif to your own wiki.
{| style="margin: 0 0 0.75em 0.75em; float: right; border-collapse: separate; border-spacing: 0;" |- style="background: #d4d0cc;" | style="padding: 0 0.5em 0 0.8em; border-top: white 1px solid; border-right: black 1px solid; border-bottom: black 1px solid; border-left: white 1px solid;" | <div style="position: relative; top: -0.5em;">[[Image:WikEd logo64x64.gif|64px]]</div> | style="padding: 0 1.5em 0em 1.5em; border-top: white 1px solid; border-right: black 1px solid; border-bottom: black 1px solid; border-left: white 1px solid;" | [/info/en/?search=User:Cacycle/wikEd '''wikEd''' Homepage] · [/info/en/?search=User_talk:Cacycle/wikEd Discussion] · [/info/en/?search=User:Cacycle/wikEd_international Translations] · '''[/info/en/?search=User:Cacycle/wikEd_help Help]''' [/info/en/?search=User:Cacycle/wikEd.js Code] |}
wikEd is fully customizable, including color schemes, language, and custom buttons and functions. Please see the wikEd customization page on how to adapt wikEd to your personal preferences.
Please post your detailed bug reports to User_talk:Cacycle/wikEd (the discussion page of this article). Please use the bug reporting form on top of the page and add your report to the bottom of the page.
Please see the gadget preference statistics. Additionally, the following search link gives you an idea how many users of the English Wikipedia are loading wikEd through their skin.js or common.js pages: Search Wikipedia.
All wikEd-related code and Wikipedia article content is released into the public domain:
I, the copyright holder of this work, hereby release it into the
public domain. This applies worldwide. If this is not legally possible: |
Please support wikEd by helping to fix the following browser and MediaWiki issues.
wikEd |
---|
Installation |
wikEd diff |
Program code |
Project |
Gadgets |
|
Translations |
|
wikEd is a full-featured edit page text editor for regular to advanced users on Wikipedia and other MediaWikis. wikEd features syntax highlighting, reference, template, and code folding, on-page Show preview and Show changes, and advanced search and replace functions. Please check the wikEd help page for details. wikEd works under all web browsers except Internet Explorer.
How to install wikEd (choose one option):
Type | Scope | Installation | Remarks |
---|---|---|---|
Gadget | Local Wikipedia language or wiki only | Select wikEd under Gadgets in your wiki preferences | The easiest option on the English Wikipedia. Not available on all wikis. |
User script | Local Wikipedia language or wiki only | Paste a small code snippet to your User:YourUsername/common.js page | |
Every Wikipedia language and MediaWiki installation | Paste a small code snippet to your meta:User:YourUsername/global.js page | ||
Site wide | Local wiki only | A wiki administrator has to paste a code snippet to the MediaWiki:Common.js page | Site wide installation for all users |
Greasemonkey/Tampermonkey | Every Wikipedia language and MediaWiki installation | Install the Greasemonkey/Tampermonkey add-on for your browser, then install wikEd by clicking here | Also works for anonymous users that are not logged in |
See wikEd installation page for more details. That page also explains how to install wikEd on non-Wikipedia wikis and on wikis without internet connection and how to create a wikEd gadget.
Simply check wikEd under the Gadget section in your Wikipedia preferences (or use one of the other installation methods from above).
Check the wikEd help page for a description of all buttons. For a local installation as a Greasemonkey user script see below.
For more information, see below or check the wikEd installation page.
See also the wikEd help page for a description of all buttons and functions. wikEd adds the following functions as buttons above the edit textarea:
See wikEd international for translations of wikEd and how to install them. wikEd has been translated into Arabic, Chinese (simplified), Chinese (traditional), Croatian, Czech, Dutch, Esperanto, Finnish, French, Galician, German, Hebrew, Hungarian, Italian, Japanese, Korean, Kazakh, Lower Sorbian, Malay, Norwegian, New Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, Sicilian, Slovak, Slovenian, Spanish, Swedish, Turkish, Upper Sorbian, and Vietnamese. Detailed instructions on creating new translations can also be found on the wikEd international page.
If you're on Wikipedia, paste the following text to your user page:
{{User:Cacycle/wikEd userbox}}
to get this userbox:
This user edits with the gadget wikEd. |
Check who is using this box.
wikEd works under Firefox, SeaMonkey, Safari, WebKit, Google Chrome, Opera (version 15 and higher) but not yet under the currently not standards-compatible Internet Explorer.
wikEd works with all native MediaWiki skins and most of their derivatives. Other supported skins include:
In general, wikEd is incompatible with scripts, add-ons, or extensions that rely on or change the standard text edit box. The reason is that wikEd replaces the normal text area with its own separate rich-text iframe. Many of these scripts will still work if wikEd is temporarily turned off by pressing the button, making the changes, and re-enabling wikEd. It is possible to make scripts compatible with wikEd (see below).
This is a short and incomplete list of scripts and gadgets that are compatible with wikEd:
This is a short and incomplete list of scripts and gadgets that are not compatible with wikEd:
The wikEd edit box is a rich-text iframe while the standard edit box is a textarea with the id wpTextbox1. Nevertheless, developers can make their script compatible with wikEd by copying the text from the wikEd iframe to the standard textbox before making their changes and then copying the content back to the iframe. The following code is cross-browser compatible and wikEd-independent:
// copy wikEd (/info/en/?search=User:Cacycle/wikEd.js) frame to wpTextbox1 textarea
if (typeof(window.wikEd.useWikEd) != 'undefined') {
if (window.wikEd.useWikEd == true) {
wikEd.UpdateTextarea();
}
}
// make the changes to the classic wpTextbox1 textarea //
// copy wpTextbox1 textarea back to wikEd frame
if (typeof(window.wikEd.useWikEd) != 'undefined') {
if (window.wikEd.useWikEd == true) {
wikEd.UpdateFrame();
}
}
A more sophisticated way to apply local changes similar to custom button handlers is shown below. The example implements a "<div>...</div>" add or remove function around selected text:
// this example code adds or removes div tags around the selected text
function TestHandler(obj) {
// select the appropriate text change target (whole, selection, cursor, focusWord, focusLine, selectionWord, or selectionLine)
// focus... is the text under the cursor; ...Word and ...Line extend the target to the start/end of the word or line
wikEd.GetText(obj, 'selection, cursor');
if (obj.selection.plain != '') {
obj.changed = obj.selection;
}
else {
obj.changed = obj.cursor;
}
// make your changes to the plain target text in obj.changed.plain
// remove the previously added formatting
if ( /&lt;div&gt;(.*?)&lt;\/div&gt;/i.test(obj.changed.plain) ) {
obj.changed.plain = obj.changed.plain.replace(/&lt;div&gt;(.*?)&lt;\/div&gt;/gi, '$1');
}
// add the text formatting
else {
obj.changed.plain = '&lt;div&gt;' + obj.changed.plain + '&lt;/div&gt;';
obj.changed.plain = obj.changed.plain.replace(/(&lt;div&gt;)( *)(.*?)( *)(&lt;\/div&gt;)/, '$2$1$3$5$4');
}
// keep the changed text selected
obj.changed.keepSel = true;
// return to wikEd.EditButton() to apply changes
return;
}
if (typeof(window.wikEd.useWikEd) != 'undefined') {
wikEd.EditButton(null, null, null, TestHandler);
}
You can also add your custom functions to hooks that are executed on events such as wikEd setup, wikEd turned on or off, and classic textarea or wikEd frame turned on. It is also possible to directly apply changes to the wikEd edit frame, please see the wikEd development page.
This section focuses on getting wikEd to work. For other problems see the wikEd help page.
You have followed the installation instructions above, but the wikEd logo is not displayed on top of the pages next to the log out link and the wikEd buttons do not appear on edit pages. Please try the following:
Every wikEd project page has a navigation box on top. You can add this template to an English Wikipedia page by adding the following code on top of the page text:
{{User:Cacycle/wikEd_template}}
The following code can be used for wikEd navigation boxes and templates on non-Wikipedia sites and non-English Wikipedia pages. The box uses external html links. If you are not on Wikipedia or another Wikimedia site like Wiktionary or Wikinews, then you have to upload the logo WikEd_logo64x64.gif to your own wiki.
{| style="margin: 0 0 0.75em 0.75em; float: right; border-collapse: separate; border-spacing: 0;" |- style="background: #d4d0cc;" | style="padding: 0 0.5em 0 0.8em; border-top: white 1px solid; border-right: black 1px solid; border-bottom: black 1px solid; border-left: white 1px solid;" | <div style="position: relative; top: -0.5em;">[[Image:WikEd logo64x64.gif|64px]]</div> | style="padding: 0 1.5em 0em 1.5em; border-top: white 1px solid; border-right: black 1px solid; border-bottom: black 1px solid; border-left: white 1px solid;" | [/info/en/?search=User:Cacycle/wikEd '''wikEd''' Homepage] · [/info/en/?search=User_talk:Cacycle/wikEd Discussion] · [/info/en/?search=User:Cacycle/wikEd_international Translations] · '''[/info/en/?search=User:Cacycle/wikEd_help Help]''' [/info/en/?search=User:Cacycle/wikEd.js Code] |}
wikEd is fully customizable, including color schemes, language, and custom buttons and functions. Please see the wikEd customization page on how to adapt wikEd to your personal preferences.
Please post your detailed bug reports to User_talk:Cacycle/wikEd (the discussion page of this article). Please use the bug reporting form on top of the page and add your report to the bottom of the page.
Please see the gadget preference statistics. Additionally, the following search link gives you an idea how many users of the English Wikipedia are loading wikEd through their skin.js or common.js pages: Search Wikipedia.
All wikEd-related code and Wikipedia article content is released into the public domain:
I, the copyright holder of this work, hereby release it into the
public domain. This applies worldwide. If this is not legally possible: |