Page MenuHomePhabricator

Section renaming breaks anchor links
Closed, DeclinedPublic

Description

Author: thomas.diesler

Description:

My Page

foo

My Section

bar

[[My Page#My Section]] will break if "My Section" is renamed


Version: unspecified
Severity: enhancement

Details

Reference
bz8928

Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 21 2014, 9:36 PM
bzimport set Reference to bz8928.
bzimport added a subscriber: Unknown Object (MLST).

thomas.diesler wrote:

We are currently authoring the JAX-WS documentation on mediawiki

http://tddell.dyndns.org/mediawiki/index.php/JAX-WS_User_Guide

ayg wrote:

What sort of heuristic would we use to figure out what the "same" section is? For instance, if
I change:

Foo

Blah blah blah bleh bleh bleh

to:

Bar

Blah blah blah

Baz

Bleh bleh bleh

what happens to the section anchor? It would probably be more coherent to have a list of
"alternative" section anchors in the wikitext itself, I suppose, but that makes things look
kind of messy (and can be done manually by adding some empty spans or whatnot, if you really
want to).

You can create manual anchors if you wish to have stable or shorter items. (eg
<span id="sec1a"></span>) or whatever.

MediaWiki's section anchors are inherently unstable due to the nature of the beast.

thomas.diesler wrote:

A special page that discovers broken section anchors would already help a lot.
Is that feasible?

robchur wrote:

(In reply to comment #4)
No.

ayg wrote:

We could probably construct such a special page, but it would require a new
database table or two, probably. Likely not worth the effort. If you want to
pursue that, please open a new bug report: separate reports for separate requests.

thomas.diesler wrote:

JBoss/RedHat is currently evaluating wiki solutions. This request poped up
during evaluation.

A seperate report is filed here: http://bugzilla.wikimedia.org/show_bug.cgi?id=8955

cheers