[[#foo|]], [[/bar|]] should be equivalent to [[#foo|foo]], [[/bar|bar]] (new use of "pipe trick")
OpenPublic

Description

Author: bugzillas+padREMOVETHISdu

Description:
In many cases a link to a named anchor for a section within the current page
would have an anchor text that is the same as the heading of the section. This
would make such links easier to type. Similar is the case with subpages. Note
that the text displayed should not have obfuscations like ".3F." used in the
anchor (e.g. ".3F." should be "?").


Version: unspecified
Severity: enhancement
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=28730

bzimport added a subscriber: wikibugs-l.
bzimport set Reference to bz845.
bzimport created this task.Via LegacyNov 9 2004, 8:20 AM
bzimport added a comment.Via ConduitNov 10 2004, 3:08 AM

gangleri wrote:

Just for your information:

If the name of a (sub-) section is repeated, " 2", " 3" ... will be append
to the name of the (transliterated) anchors. See
[[test:User:Gangleri/tests/anchors#dummy 2]]
http://test.wikipedia.org/wiki/User:Gangleri/tests/anchors#dummy_2.

Three other anchors are used in there too:
<font id="á" />á with á as a special character
<div id="5" />5
<font id="6" />6

See [[test:User:Gangleri/tests/anchors#5]]. Works.
See [[test:User:Gangleri/tests/anchors#6]]. Works.
See [[test:User:Gangleri/tests/anchors#á]] translates to
http://test.wikipedia.org/wiki/User:Gangleri/tests/anchors#%C3%A1 and will
not work.
http://test.wikipedia.org/wiki/User:Gangleri/tests/anchors#á with á not
translated would work only if I copy and paste it in my browser (IE).

Regards Reinhardt See also [[bugzilla:670|bug 670]].

bzimport added a comment.Via ConduitNov 10 2004, 9:25 PM

0paddu wrote:

Oops! Reinhardt WIEWE seems to have misunderstood what I meant. I'm not worried
about .3F. etc. present in the anchor. What I'm saying is [[#foo?|]] should
produce <a href="#foo.3F." ...>foo?</a> and not <a href="#foo.3F."
...>foo.3F.</a>. Currently [[#foo?|]] does the same as <nowiki>[[#foo?|]]</nowiki>.

bzimport added a comment.Via ConduitNov 29 2004, 3:55 AM

mrnobo1024 wrote:

You can already do this for the subpages case. Just add an extra
slash, like /bar/

bzimport added a comment.Via ConduitFeb 8 2005, 11:49 PM

rowan.collins wrote:

*** Bug 1489 has been marked as a duplicate of this bug. ***

bzimport added a comment.Via ConduitFeb 8 2005, 11:51 PM

rowan.collins wrote:

[added phrase "pipe trick" to the summary to make this bug more searchable]

bzimport added a comment.Via ConduitMar 14 2005, 11:07 AM

gangleri wrote:

Dear friends,

See [[meta:Help:Piped link#Automatic conversion of the wikitext (pipe trick)]]:
"if there is a text in parentheses at the end it will be removed"

Many locations are using a comma as [[Chicago, Illinois]]. [[Chicago,
Illinois|]] does not generate a link.

It should be evaluated:

  • if comma could trigger the "piped trick"
  • if other characters as / should trigger it also
  • if the pipe trick should generate always a link ( now not "simple" titles in

the article namespace as [[New York|]] )

  • if "multiple" pipes should remouve recursively one prefix after the other

Please see
[[Wikipedia talk:Piped link#Pipe trick for additional 50.2C000 titles]]
http://en.wikipedia.org/wiki/Wikipedia_talk:Piped_link#Pipe_trick_for_additional_50.2C000_titles

Additional test cases at [[User:Gangleri/tests/unknown]]

Best regards Reinhardt [[User:gangleri]]

bzimport added a comment.Via ConduitJun 18 2005, 7:58 AM

gangleri wrote:

Hallo!

Please see some test examples at
http://jadesukka.homelinux.org:8180/betawiki/Project:Piped_links

The "piped link trick" should work whenever there is an agreement about a
*single* interpretation.

It is questionable if [[Project:FAQ#Q 10|]] - "Project:FAQ#Q 10|" should be
[[Project:FAQ#Q 10|FAQ#Q 10]] - "Project:FAQ#Q 10|FAQ#Q 10" according to the
documentation or not.

Best regards Reinhardt [[user:gangleri]]

bzimport added a comment.Via ConduitAug 2 2005, 9:03 PM

rowan.collins wrote:

*** Bug 3003 has been marked as a duplicate of this bug. ***

bzimport added a comment.Via ConduitAug 6 2005, 2:13 AM

ui2t5v002 wrote:

"Just add an extra slash, like /bar/"

That's bizarre. Why use two different syntaxes for the same thing?

bzimport added a comment.Via ConduitAug 11 2005, 1:59 PM

rowan.collins wrote:

*** Bug 3114 has been marked as a duplicate of this bug. ***

bzimport added a comment.Via ConduitAug 11 2005, 2:00 PM

rowan.collins wrote:

Pasting an additional comment from dupe:

This would be only a part of the enhancement. For full usability, full paths
should also be converted, e. g. [[Programming in Ada/Types/Strings|]] should be
converted to [[Programming in Ada/Types/Strings|Strings]].

bzimport added a comment.Via ConduitAug 11 2005, 2:12 PM

ui2t5v002 wrote:

(In reply to comment #11)

Pasting an additional comment from dupe:
> e. g. [[Programming in Ada/Types/Strings|]] should be
> converted to [[Programming in Ada/Types/Strings|Strings]].

See also Bug 3058:

Multiple pipes should remove multiple prefixes: [[Foo:Bar:Baz||]] =
[[Foo:Bar:Baz|Baz]]

bzimport added a comment.Via ConduitAug 8 2008, 6:10 AM

fantasy wrote:

Is there any chance that this will ever happen?

DanielFriesen added a comment.Via ConduitAug 8 2008, 4:37 PM

(In reply to comment #9)

"Just add an extra slash, like /bar/"

That's bizarre. Why use two different syntaxes for the same thing?

Pipe trick substitutes. The trailing / just hides the /.
Quite simply /bar/ stays as /bar/ while [[Foo:Bar|]] becomes [[Foo:Bar|Bar]].

Actually, # is a similar case. Why not go with that and #anchor#.

Chad added a comment.Via ConduitJul 13 2009, 6:39 PM
  • Bug 12285 has been marked as a duplicate of this bug. ***
Chad added a comment.Via ConduitJul 13 2009, 6:41 PM
  • Bug 14734 has been marked as a duplicate of this bug. ***
bzimport added a comment.Via ConduitFeb 7 2010, 1:55 AM

conrad.irwin wrote:

*** Bug 17675 has been marked as a duplicate of this bug. ***

bzimport added a comment.Via ConduitFeb 7 2010, 2:17 AM

conrad.irwin wrote:

Fixed in r62076

bzimport added a comment.Via ConduitJul 29 2010, 12:25 PM

bugzilla.wikimedia wrote:

(In reply to comment #9)

That's bizarre. Why use two different syntaxes for the same thing?

Omegatron, [[/bar] and /bar/ refer to two different pages.

bzimport added a comment.Via ConduitFeb 24 2011, 7:53 PM

circeus wrote:

So, what IS the status on this? It makes editing of glossary-type pages with heavy internal cross-referencing incredibly tedious, not to mention 90% of the Wiktionary links would benefit from this (especially if the syntax applied to [[foo#bar|]]).

bzimport added a comment.Via ConduitApr 9 2011, 6:28 AM

bud0011 wrote:

(In reply to comment #21)

So, what IS the status on this? It makes editing of glossary-type pages with
heavy internal cross-referencing incredibly tedious, not to mention 90% of the
Wiktionary links would benefit from this (especially if the syntax applied to
[[foo#bar|]]).

Apparently... no where yet... :(

MarkAHershberger added a comment.Via ConduitApr 12 2011, 3:22 PM

Brion has a new parser is under development right now and this enhancement is on his radar for that.

He7d3r added a comment.Via ConduitAug 7 2012, 3:51 PM

FYI: the new parser is documented on [[mw:Parsoid]].

Add Comment

Column Prototype
This is a very early prototype of a persistent column. It is not expected to work yet, and leaving it open will activate other new features which will break things. Press "\" (backslash) on your keyboard to close it now.