User talk:Supadawg/secedit.js
SecEdit is an inline section editor; in other words, you can edit sections of a Wikipedia article without going to a separate page. It also supports previewing and viewing changes inline.
To install and use:
- SecEdit is only tested on Firefox 1.5 and above, so you need it to continue. It may work on Safari and Opera, but I haven't tried it yet.
- Copy the following to your common.js:
importScript('User:Supadawg/secedit.js');
- Clear your cache
- Go to a normal article and click on the [edit] link directly to the right of a section title. In a second or two, the normal editing box should appear, replacing the section text. Clicking Show preview or Show changes will cause the preview or changes to appear directly above the edit box. When you're done, click Save page as normal. The [edit] link has been replaced by [cancel], which will restore the previous text.
- Please share any comments or bugs on this page!
Bug found
[edit]This script is failing for me on Wikipedia:Administrators' noticeboard and related pages. (I'm running Firefox 1.5.0.9 on WinXP, btw.) I'm pretty sure it's because the title has an apostrophe in it. Any chance of fixing it? Thanks for the wonderful script. – Anþony talk 02:45, 27 December 2006 (UTC)
- Thanks, it's fixed now. If you clear your cache you should be able to edit the page. Supadawg (talk • contribs) 20:55, 27 December 2006 (UTC)
Hows this meant to work
[edit]- How do I even use this
- Whats it meant to do? I copied the contents to my monobook.js, bypassed cache and theres no difference.
IE7. --Alfakim-- talk 19:04, 7 January 2007 (UTC)
- I really should add a description. First of all, it won't work for you, as you use Internet Explorer, and it's only tested in Firefox. If you had Firefox, you would go to a normal article, and click on one of the "edit" links of a section (directly to the right of the section title). The text of the section would be replaced by an edit box. It has the ability to preview, view changes, and, of course, cancel. Supadawg (talk • contribs) 21:48, 7 January 2007 (UTC)
- Any chance of getting it to work in IE? Any different scripts you know of that do? --Alfakim-- talk 18:22, 8 January 2007 (UTC)
- Honestly, I don't currently have the time to work around every IE-specific bug, as well as fixing the differences between IE 6 and 7, which apparently are manifold (I have other projects). If there is enough demand for it, I could try it, though. You could try QuickEdit, but I'm not sure if that works in IE either, and it doesn't have "Preview" and "Show changes" options. However, you could always switch to a standards compliant browser ;) Supadawg (talk • contribs) 00:51, 10 January 2007 (UTC)
- Any chance of getting it to work in IE? Any different scripts you know of that do? --Alfakim-- talk 18:22, 8 January 2007 (UTC)
Safari 3
[edit]Seems to work in Safari 3. Just so you know :D --TheDJ (talk • contribs) 20:03, 12 July 2007 (UTC)
Bug
[edit]I followed the instructions for installation, but whenever I click on a section edit link, the section sort of collapses, leaving only the title of the section. The edit box never appears. --DearPrudence 04:06, 12 August 2007 (UTC)
- The script seems to work in Firefox and Opera but not in IE ∴ Alex Smotrov 17:18, 15 August 2007 (UTC)
- I am using Firefox. --DearPrudence 06:06, 16 August 2007 (UTC)
Question...
[edit]How can I make this script work withwikEd? That is to say, How do I get the extra edit functions and buttons available when using this tool as none are there currently. Wikidudeman (talk) 16:46, 27 September 2007 (UTC)
- I don't think it's easy to do without Cacycle's support. —AlexSm 17:06, 17 March 2008 (UTC)
script edits next section
[edit]Somehow the script is editing the section 2 when I click the edit link for section 1... Any Idea why this is happening? Btw I am using the modern skin. Thanks for the great script! Waldir talk 16:44, 17 March 2008 (UTC)
- I think I can answer this one. The script is not designed properly, and is not compatible with zero section [edit] link, which you probably installed as a gadget. —AlexSm 17:06, 17 March 2008 (UTC)
- I guess I prefer the inline section editing to the zeroth section edit link =P If you eventually refactor the code so it is compatible, let me know ;) Waldir talk 03:43, 18 March 2008 (UTC)
- I made a quick change and created User:Nableezy/secedit.js which is this script with the small fix to work with section 0. All I had to do was change the url from
var editURI = "http://en.wikipedia.org/w/index.php?title="+encodeURIComponent2(pagetitleRe.exec(decodeURI(editSecs[i].childNodes[k].getAttribute("href")))[2]).replace(/\"/gi, "%22").replace(/\'/gi, "%27")+"&action=edit§ion="+secCount;
var editURI = "http://en.wikipedia.org/w/index.php?title="+encodeURIComponent2(pagetitleRe.exec(decodeURI(editSecs[i].childNodes[k].getAttribute("href")))[2]).replace(/\"/gi, "%22").replace(/\'/gi, "%27")+"&action=edit§ion="+(secCount-1);
feel free to use. Nableezy (talk) 01:41, 30 January 2009 (UTC)
- I made a quick change and created User:Nableezy/secedit.js which is this script with the small fix to work with section 0. All I had to do was change the url from
- I guess I prefer the inline section editing to the zeroth section edit link =P If you eventually refactor the code so it is compatible, let me know ;) Waldir talk 03:43, 18 March 2008 (UTC)
- Just tried it, seems to work fine, but since I haven't been using the original script for a while, I'm left wondering, is it ok that the toolbar doesn't show up? Would it be possible to add it? --Waldir talk 20:48, 31 January 2009 (UTC)
- Thats going to take some thinking. Let me see what I can do. Nableezy (talk) 01:17, 2 February 2009 (UTC)
- Just tried it, seems to work fine, but since I haven't been using the original script for a while, I'm left wondering, is it ok that the toolbar doesn't show up? Would it be possible to add it? --Waldir talk 20:48, 31 January 2009 (UTC)
Umm, right now it opens the next section whenever and wherever I click on edit... This started only a few days ago. --Illythr (talk) 22:35, 8 September 2008 (UTC)
- Hmm, seems to be a Firefox 3.0.0.1 problem... --Illythr (talk) 22:41, 8 September 2008 (UTC)
Epiphany
[edit]It does not seem to work with Epiphany (browser). NerdyNSK (talk) 19:20, 12 September 2008 (UTC)
Does not work
[edit]Script does not work. FF 3.5.9. I'm trying to use it here --Alex Blokha (talk) 11:14, 1 May 2010 (UTC)
Works on Firefox 4
[edit]This works on Firefox 4.0.1. Also, restart Firefox instead of just purging the page, otherwise it won't work. Samwb123T-C-E 23:05, 10 June 2011 (UTC)
Chrome
[edit]Works in Google Chrome. - Presidentman talk · contribs Random Picture of the Day (Talkback) 11:28, 2 August 2012 (UTC)
wikEd/ProveIt
[edit]Not compatible with wikEd or ProveIt. - Presidentman talk · contribs Random Picture of the Day (Talkback) 14:52, 2 August 2012 (UTC)
common.js
[edit]The code appears to work in the now default Vector skin as well as Monobook, so I have changed the link to monobook.js to common.js, which contains common code for all skins. If it doesn't work for some skins, please note this in the instructions, and perhaps change the link to skin.js, which will redirect to the code file for your skin. Hgrosser (talk) 22:52, 23 January 2013 (UTC)