Last modified: 2014-09-17 11:41:38 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 T18962, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 16962 - Provide a non-JavaScript means of including a "Complete list" link in the interlanguage sidebar
Provide a non-JavaScript means of including a "Complete list" link in the int...
Status: NEW
Product: Wikimedia
Classification: Unclassified
Interwiki links (Other open bugs)
unspecified
All All
: Low enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on: 64786
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-10 23:58 UTC by rememberthedot
Modified: 2014-09-17 11:41 UTC (History)
4 users (show)

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


Attachments
Proposed patch v1 (2.29 KB, patch)
2009-01-10 23:58 UTC, rememberthedot
Details

Description rememberthedot 2009-01-10 23:58:58 UTC
Created attachment 5660 [details]
Proposed patch v1

Currently many Wikimedia wikis use JavaScript to add a "Complete list" link to the bottom of the interwiki list on the main page. Since this is clearly a desired feature, it would be best to eliminate the need for JavaScript and instead implement this in Wikimedia's site configurations.

I'm including a patch that adds [[completelist:]] as a "language" so that it can be included in the language links. I suggest that completelist: correspond to http://meta.wikimedia.org/wiki/$1 which should work well for all Wikimedia wikis.
Comment 1 Alex Z. 2009-02-06 05:53:52 UTC
The "Complete list" thing is basically one line of JS:
addPortletLink('p-lang', 'http://meta.wikimedia.org/wiki/List_of_Wikipedias', 'Complete list', 'interwiki-completelist', 'Complete list of Wikipedias')

Creating a "fake language" for use on the main page interwiki list is taking a local JS hack (if one can even call it that, addPortletLink is designed for things like this) and turning it into a hack in MediaWiki core. I really don't see why this is desirable. 
Comment 2 rememberthedot 2009-02-06 06:15:06 UTC
I don't know if there is a better way to do this in MediaWiki. I do know that using JavaScript to do this is suboptimal -- it would be best to serve the desired link as part of the document in the first place, rather than using JavaScript to throw it in afterwards. Between the clients that do not have JavaScript enabled, and a rare few like Dillo that do not support JavaScript at all, there are about 6% of web users that the JavaScript hack will not work for: http://www.thecounter.com/stats/2009/January/javas.php
Comment 3 Alex Z. 2009-02-06 18:16:30 UTC
I really don't think 6% of people not seeing a tiny little link that's only going to be used on 1 page per site, on Wikimedia sites only, really justifies adding a hack to core. Its an extremely trivial loss of function, and at least enwiki has a link to the list of Wikipedias elsewhere on the Main Page, so people with JS actually get 2 links. The interlanguage links are supposed to be links to other languages, anything that adds a link to something that isn't another language is going to be a hack to some degree no matter how its done. One of the reasons MediaWiki has sitewide JS and CSS customizable through the wiki is so that end users can add things like this, without having to hack the core code, it even provides the addPortletLink function to add links to the various portlets.
Comment 4 MZMcBride 2009-02-06 18:54:22 UTC
Hack this into the WikimediaMessages extension? :-)
Comment 5 rememberthedot 2009-02-06 19:47:20 UTC
All I'm asking for is a way to provide this feature without having to hack it in with JavaScript. The patch I posted is one way to do it; is is not the only way and clearly it is not a desirable way.
Comment 6 p858snake 2011-04-30 00:09:24 UTC
*Bulk BZ Change: +Patch to open bugs with patches attached that are missing the keyword*
Comment 7 Andre Klapper 2013-07-24 13:09:00 UTC
Setting "patch-reviewed" keyword as per comment 5.
Comment 8 MZMcBride 2013-07-25 03:26:22 UTC
(In reply to comment #4)
> Hack this into the WikimediaMessages extension? :-)

This could also be hacked into one of the Wikimedia configuration files. In any case, I think this is an easy bug to resolve; marking it as such accordingly.
Comment 9 This, that and the other (TTO) 2013-11-12 00:18:54 UTC
Comment on attachment 5660 [details]
Proposed patch v1

Marking patch obsolete, there is no way this would be accepted now.
Comment 10 This, that and the other (TTO) 2014-02-02 04:24:16 UTC
See Gerrit change #110832. This is the first step. Then to write a (very simple) extension, or even just consume the hook in CommonSettings.php (although I don't think Reedy would like that).
Comment 11 This, that and the other (TTO) 2014-02-20 09:05:38 UTC
(In reply to This, that and the other from comment #10)
> See Gerrit change #110832. This is the first step. 

Clearly not. But we can always use SkinTemplateOutputPageBeforeExec instead, so it's not a big deal.

> Then to write a (very simple) extension

It wouldn't be quite that simple, but certainly possible.

I see three implementation paths here:

* Store data relating to additional links in a $wg configuration variable. 
  Inflexible - only server admins could change the "Complete list" link and
  its target, and which pages it appears on.

* Implement an extension that reads parser function syntax like
  {{extralanguagelink:meta:List of Wikipedias|Complete list|class=whatever}}.
  Definitely doable, but tricky and possibly overkill?

* Add (say) "listofwikipedias:" to the [[m:interwiki map]], and set
  "listofwikipedias" as an additional language link prefix, a la the proposed
  Gerrit change #111390. Then we can include an interwiki to
  [[listofwikipedias:]] on the Main Page, which would appear in the list of
  language links (the link text would be read from a MediaWiki: page). Least
  effort, but seems very unclean.  (Then again, Extension:RelatedSites is
  an example of a horribly unclean implementation that somehow got deployed
  on the WMF cluster, so there's a precedent...)
Comment 12 Gerrit Notification Bot 2014-06-21 01:42:15 UTC
Change 141099 had a related patch set uploaded by TTO:
Add additional interwiki links as requested in various bugs

https://gerrit.wikimedia.org/r/141099
Comment 13 Gerrit Notification Bot 2014-09-16 23:08:17 UTC
Change 141099 merged by jenkins-bot:
Add additional interwiki links as requested in various bugs

https://gerrit.wikimedia.org/r/141099
Comment 14 This, that and the other (TTO) 2014-09-17 11:41:38 UTC
Patch is merged; this is just waiting on a manual update of interwiki.cdb

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


Navigation
Links