https://bugzilla.wikimedia.org/show_bug.cgi?id=29723
Web browser: ---
Bug #: 29723
Summary: mw.util.wikiGetlink() should defaults to the current
page name
Product: MediaWiki
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Keywords: easy
Severity: normal
Priority: Unprioritized
Component: Javascript
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Classification: Unclassified
Created attachment 8744
--> https://bugzilla.wikimedia.org/attachment.cgi?id=8744
Example
Currently, if a user calls mw.util.wikiGetlink()[1] on [[Example]] it will be
returned
"http://en.wikipedia.org/wiki/undefined"
which is not very useful.
Considering that it is common[2] to have constructs like
mw.util.wikiGetlink( mw.config.get( 'wgPageName' ) ) + '?foo=bar&baz=meh'
I propose the addition of wgPageName as a default value for the "str" parameter
of this function, so that users coudl then use mw.util.wikiGetlink() on
[[Example]] to get
"http://en.wikipedia.org/wiki/Example"
[1]
http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/resources/mediawiki/mediawiki.util.js?view=markup#l134
[2] See e.g.: [[MediaWiki:Gadget-purgetab.js]], [[pt:MediaWiki:Common.js]],
[[s:MediaWiki:Common.js]], etc...
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l