Last modified: 2007-08-07 02:58:54 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 6067 - {{BASEPAGENAME}} does not return topmost page name
{{BASEPAGENAME}} does not return topmost page name
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 10136 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-24 02:26 UTC by emddudley
Modified: 2007-08-07 02:58 UTC (History)
4 users (show)

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


Attachments

Description emddudley 2006-05-24 02:26:59 UTC
Currently {{BASEPAGENAME}} returns the parent page of the current page; it
essentially acts like [[../]]. For example, using {{BASEPAGENAME}} on
"Wikipedia:ExamplePage/Archive_1/Subpage" it returns "ExamplePage/Archive 1".

The current behavior is misleading. I expect {{BASEPAGENAME}} to get the topmost
name, not the immediate parent. When using {{BASEPAGENAME}} on
"Wikipedia:ExamplePage/Archive_1/Subpage" I think it should return "ExamplePage".

I propose modifying the current behavior of {{BASEPAGENAME}} (getBaseText() in
Title.php) to return the topmost name, as I believe this was the original intent
of bug 5845.
Comment 1 Rob Church 2006-05-24 09:05:31 UTC
This was not the intended behaviour, and it doesn't make sense to give subpages
any more special treatment than they already have, especially since they mean
very little to MediaWiki as it is.
Comment 2 Raimond Spekking 2007-06-04 16:52:56 UTC
*** Bug 10136 has been marked as a duplicate of this bug. ***
Comment 3 Rob Church 2007-06-04 17:34:43 UTC
Introduced TITLEPARTS parser function in r22711, to allow obtaining whatever number of segments of a page title the user desires.
Comment 4 fdcn 2007-08-07 02:58:54 UTC
can do work as below?

{{#titleparts:Help:Link/a/b|-1}} gives b

{{#titleparts:Help:Link/a/b|-2}} gives a/b

{{#titleparts:Help:Link/a/b|-3}} gives Help:Link/a/b


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


Navigation
Links