Page MenuHomePhabricator

Using #ask in a #formlink
Closed, InvalidPublic

Description

Author: mail

Description:
I am trying to use an inline query (#ask) within a #formlink, something like this:

{{ #formlink: Project|Create project|link|Project[Number prefix]={{ #ask: [[Category:Year-Letter mapping]] [[Year::{{ #time: Y | {{CURRENTYEAR}} }}]] | ?Letter | link=none | format=template | template=One string | limit=1 }}{{ #time: m }} }}

I know it looks ugly and all, but it would be great to get this Year-Letter mapping, that we need for project numbers, to be done by software.

The output of that link could be:

https://server/wiki/index.php/Special:AddData/Project?Project[Number prefix]=[[SMW::off]]C[[SMW::on]]10

So year 2008 maps to letter C, the month number being inserted is 10, which is all ok. But: Obviously the '[[SMW::off]]' and '[[SMW::on]]' parts should not appear in the URL. Can this be resolved?


Version: unspecified
Severity: normal

Details

Reference
bz15906

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:20 PM
bzimport set Reference to bz15906.

mail wrote:

Forgot to mention: I also tried to put the #ask query into a template for less uglyness, with the same result.

mail wrote:

Not specific to Semantic Forms, rather an issue with SMW.