Last modified: 2008-11-18 15:20:08 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T10260, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 8260 - Magic word to add supplemental text above edit box for a particular page
Magic word to add supplemental text above edit box for a particular page
Status: RESOLVED DUPLICATE of bug 15102
Product: MediaWiki
Classification: Unclassified
Page editing (Other open bugs)
unspecified
All All
: Normal enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-12-14 12:13 UTC by Danny B.
Modified: 2008-11-18 15:20 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Danny B. 2006-12-14 12:13:37 UTC
Please add either {{EDITINTRO|<pagename>}} or {{editintro:<pagename>}} (or any
other form you prefer)

It should modify the URL of "edit" tab with adding of (already existing)
editintro= parameter to query string.

Thanks
Comment 1 Rob Church 2006-12-14 19:08:22 UTC
I don't quite understand what's meant here, or what this would be used for.
Comment 2 Danny B. 2006-12-15 00:09:49 UTC
If you load the article, it has "edit" tab and when you click on it, you'll get
the regular editing page.

The idea is, if the article had this magic word inside, then when you click on
"edit" tab, it would show some information (= the content of <pagename> in
parameter) above editing window.

Therefore the edit tab link would be
/w/index.php?title=<article>&action=edit&editintro=<pagename_from_magic_word_parameter>
instead of current
/w/index.php?title=<article>&action=edit
Comment 3 Rob Church 2006-12-15 10:29:06 UTC
Example applications? There might be a more appropriate means of doing this.
Comment 4 RockMFR 2008-06-11 21:38:24 UTC
A question much like this one came up at http://en.wikipedia.org/w/index.php?title=Wikipedia:Village_pump_%28technical%29&diff=218485159 . Assuming you have a wiki that isn't prone to abuse, a general solution to this problem that would not require changes to MediaWiki would involve something like this:

1) Create Template:EDITINTRO with the following contents:

<div id="editintro-name" style="display:none">{{{1|}}}</div>

2) Add something like this to your wiki's common.js:

addOnloadHook(function() {
  if (document.getElementById('editintro-name') && document.getElementById('ca-edit')) {
    var editLinks = document.getElementById('ca-edit').getElementsByTagName('a')
    if (editLinks.length > 0) {
      editLinks[0].href += '&editintro=' + document.getElementById('editintro-name').innerHTML
    }
  }
});

3) Create a template containing your editintro (e.g., Template:Foobar).

4) Place {{EDITINTRO|Template:Foobar}} on any page.
Comment 5 Chad H. 2008-11-18 15:20:08 UTC

*** This bug has been marked as a duplicate of bug 15102 ***

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links