This question, like the one before it, is actually about Semantic Forms, since that's where the #arraymap function is defined (though in fairness, it's not at all obvious that that's where it's defined). But you should be able to create a table just by using #arraymap, by replacing the current formatting in the template with something like this:


{{ #arraymap: {{{property1}}}||x| <tr><td>[[property1::x]]</td></tr> }}

You'll have to use HTML, since wiki-text for tables uses pipes, which will confuse the parser. I've never actually tried such a layout, but in theory it should work.


On Jan 30, 2008 10:12 AM, Gustavo Felhberg <> wrote:
Hello there,

I have some templates of categories that has more than one value for property. For example, the definition of the template has this idea:


{| style="width: 95em; font-size: 90%; border: 1px solid #aaaaaa; background-color: #f9f9f9; color: black; margin-bottom: 0.5em; margin-left: 1em; padding: 0.5em; float: right; clear: right; text-align:left;"
! style="text-align: center; background-color:#ccccff;" colspan="2" |<big>{{PAGENAME}}</big>
! Property1
| {{ #arraymap: {{{property1}}}|, |x| [[property1::x]] }}

The problem is that the values of the properties are displayed separated by commas. I'd like to present them in a table format. I could make a simple query to present this information as a table (the output would be perfect), but this way I'll have 2 lists of results (one in a comma sequence and another as a table). If I just remove the line {{ #arraymap: {{{property1}}}|, |x| [[property1::x]] }}, this page will lose this property and I don't want this.

Do anyone know if there is a way to manipulate the output of a array query? (hide this result, for instance)

Thanks a lot.

Gustavo Felhberg
Mestrando em Informática
Universidade Federal do Espírito Santo

This email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
Semediawiki-user mailing list