Page MenuHomePhabricator

Asking for the category of a page: "link=none" does not print category namespace and "default=" does not print default value
Closed, DeclinedPublic

Description

Author: hansch

Description:

  1. enter the following query into an article which is instance of category Foo:

{{#ask:[[{{FULLPAGENAME}}]]|?Category=|default=|link=none}}

  1. expected result is (en is local language):

Category:Foo

> instead "Foo" is printed (without namespace).

thats wrong.


Version: unspecified
Severity: normal

Details

Reference
bz27990

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 11:29 PM
bzimport set Reference to bz27990.

Why is this wrong? Does the documentation state the behavior is different? If so, please link to it. In any case, what is the problem with the current behavior?

hansch wrote:

I expect that option "link=none" always prints out full page name,
like in:

a) {{#ask:[[Category:Foo]]|default=|link=none}}

> prints (since Category:Bar is instance of Category:Foo):

Category:Bar

b) {{#ask:[[Category:Foo]]|?Link=|default=|link=none}}

> prints (since Category:Foo contains "[[Link::Category:Bar]]")

Category:Bar

It is a matter of consistency if "link=none" prints out the
full page name in this case, too:

{{#ask:[[Category:Bar]]|?Category=|default=|link=none}}

>Category:Foo (GOOD)

>Foo (BAD)

hansch wrote:

In addition:

"default=foo" does not work, too.

test:
{{#ask:[[{{FULLPAGENAME}}]]|?Category|default=nocategory}}

Aklapper subscribed.

The Semantic MediaWiki developers requested in https://phabricator.wikimedia.org/T64114 to move their task tracking to https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues and to close remaining tasks in Wikimedia Phabricator. If you still face the problem reported in this task in a supported version of SMW, please feel free to transfer your report to https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues . We are sorry for the inconvenience.