Wikipedia talk:AutoEd
This page has archives. Sections older than 180 days may be automatically archived by Lowercase sigmabot III when more than 2 sections are present. |
Dashes
[edit]Can someone help me with AutoEd customization to add User:Ohconfucius/dashes.js? I'm really confused with the instructions. 𝙹𝚒𝚢𝚊𝚗 忌炎 (𝚃𝚊𝚕𝚔) 19:21, 23 October 2024 (UTC)
- Hey! Add the following, and make sure it is below the imports for dashes and autoedcomplete:Aaron Liu (talk) 21:01, 23 October 2024 (UTC)
function autoEdFunctions() { //Activates individual modules when "auto ed" tab is clicked var $textbox = $( '#wpTextbox1' ); var txt = $textbox.textSelection('getContents'); txt = autoEdUnicodify(txt); txt = autoEdISBN(txt); txt = autoEdWhitespace(txt); txt = autoEdUnicodeHex(txt); txt = autoEdWikilinks(txt); txt = autoEdHTMLtoWikitext(txt); txt = autoEdHeadlines(txt); txt = autoEdUnicodeControlChars(txt); txt = autoEdTemplates(txt); txt = autoEdTablestoWikitext(txt); txt = autoEdExtraBreaks(txt); txt = autoEdLinks(txt); txt = autoEdDashes(txt); txt = autoEdFullwidth(txt); txt = autoEdCurlyFixer(txt); if(txt===$textbox.textSelection('getContents')){ autoEdTag = ""; mw.notify("No changes required!"); } else $textbox.textSelection('setContents', txt); }
- This is wonderful. I really appreciate your help. So many thank you. 𝙹𝚒𝚢𝚊𝚗 忌炎 (𝚃𝚊𝚕𝚔) 21:04, 23 October 2024 (UTC)
- @Aaron Liu A question when importing those to my common.js it should be like this:
Line1 = Dashes script
Is that right? 𝙹𝚒𝚢𝚊𝚗 忌炎 (𝚃𝚊𝚕𝚔) 21:15, 23 October 2024 (UTC)
Line2 = AutoEd script
Line3 = Custom text- no, the autoed one first. That should work Aaron Liu (talk) 21:21, 23 October 2024 (UTC)
- I added it but AutoEd was gone in the tools and dashes duplicated. Could you take a look at my User:Windborne Rider/common.js? Did I do it right? 𝙹𝚒𝚢𝚊𝚗 忌炎 (𝚃𝚊𝚕𝚔) 21:30, 23 October 2024 (UTC)
- Try importing AutoEd complete.js at the very start of the file Aaron Liu (talk) 22:01, 23 October 2024 (UTC)
- I added it but AutoEd was gone in the tools and dashes duplicated. Could you take a look at my User:Windborne Rider/common.js? Did I do it right? 𝙹𝚒𝚢𝚊𝚗 忌炎 (𝚃𝚊𝚕𝚔) 21:30, 23 October 2024 (UTC)
- no, the autoed one first. That should work Aaron Liu (talk) 21:21, 23 October 2024 (UTC)
why does AutoEd trash references?
[edit]Here is what it let a user do to an article the other day: it closed a references tag and blew away the reference definitions. -- mikeblas (talk) 14:47, 25 October 2024 (UTC)
- As the page says, users are responsible for inspecting their edits. This user clearly did not. Aaron Liu (talk) 15:05, 25 October 2024 (UTC)
- I would be surprised if there is code in the default AutoEd setup that adds a closing slash to <references>, which is used in 4,000 articles. I suspect that the editor did that one manually. User talk:Trivialist is probably the best place to raise this issue. – Jonesey95 (talk) 12:57, 28 October 2024 (UTC)
- Actually, Wikipedia:AutoEd/htmltowikitext.js#L-18 does that by default. Aaron Liu (talk) 13:24, 28 October 2024 (UTC)
- Well, color me surprised! That looks like a bug to me, since <references> is a supported feature of MediaWiki. That line should probably be removed from the AutoEd code. – Jonesey95 (talk) 15:03, 29 October 2024 (UTC)
- Actually, Wikipedia:AutoEd/htmltowikitext.js#L-18 does that by default. Aaron Liu (talk) 13:24, 28 October 2024 (UTC)
- I would be surprised if there is code in the default AutoEd setup that adds a closing slash to <references>, which is used in 4,000 articles. I suspect that the editor did that one manually. User talk:Trivialist is probably the best place to raise this issue. – Jonesey95 (talk) 12:57, 28 October 2024 (UTC)
Edit requests to fix only-slightly–common bugs
[edit]![]() | This edit request to Wikipedia:AutoEd/htmltowikitext.js has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Remove lines 17 and 18, per the section immediately above. The part about whitespace isn't nearly worth as much as list-defined references. Aaron Liu (talk) 15:01, 28 December 2024 (UTC)
![]() | This edit request to Wikipedia:AutoEd/core.js has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Change line 98 to if( document.getElementById('ca-edit') && !document.getElementById( autoEdLinkLocation ) ) {
to prevent self-executing AutoEd modules like Dashes from accidentally adding multiple AutoEd portlets. Aaron Liu (talk) 15:01, 28 December 2024 (UTC)
Done both. * Pppery * it has begun... 16:30, 28 December 2024 (UTC)
- @Pppery Could you undo the second one? It looks like it broke everything. Sorry. Aaron Liu (talk) 16:38, 28 December 2024 (UTC)
- As you wish. * Pppery * it has begun... 16:39, 28 December 2024 (UTC)
- @Pppery Okay, this should work, I tested this one out:
if( document.getElementById( 'ca-edit' ) && !document.getElementById( 'ca-AutoEd' ) ) {
. Thanks in advance! Aaron Liu (talk) 16:48, 28 December 2024 (UTC)
- @Pppery Okay, this should work, I tested this one out:
- As you wish. * Pppery * it has begun... 16:39, 28 December 2024 (UTC)
- @Pppery Could you undo the second one? It looks like it broke everything. Sorry. Aaron Liu (talk) 16:38, 28 December 2024 (UTC)