Hello Yaron
Ya know I was only trying to give some feedback about the extension.
I identified a user-level issue, suggested a solution
... eliminate the (redundant and non-conforming) parameter-name "_table="
that's my 2 cents.. cheers! /john

On 3/31/2015 3:06 PM, Yaron Koren wrote:
Hi,

I don't know what you mean by the vertical bar thing.
'pipe' is another name
Again, most MediaWiki parser functions take either the form:
{{#function_name:a|b|c}}

...or:

{{#function_name:a=b|c=d|e=f}}
yep and also {{#function_name:|a=b|c=d|e=f}}

#cargo_declare takes the latter form; and the parameters can actually go in any order.
yes, the former -- {{#function_name:a|b|c}} -- is usual, the latter not at all ... the implied rule usually being the first parameter is one *required* by the parser function Other than #set (and #cargo_*), I don't know off-hand of other parser functions that use the latter. ...#ask is not an exception to me, it's a good model - no confusion to anyone. ...#subobject follows the same pattern as #ask, with a 'default' value if its name isnt specified.

C'mon even #compound_query and #set_recurring_event -- your functions -- do the former.

   {{#function_name:  *value* |a=|b=|c=}}


-Yaron

On Tue, Mar 31, 2015 at 5:22 PM, John McClure <jmccl...@hypergrove.com <mailto:jmccl...@hypergrove.com>> wrote:

    Hi Yaron,
    To the user, 'field_x' looks and acts like a named parameter.
    And to the user, _table is even more so a named parameter, as it
    is predefined by the extension.
    But to the user, this _table parameter appears to be missing a
    vertical-bar.
    And of course a vertical-bar *can* precede that name=value, but
    the documentation says not to have one.
    So it's a source of confusion, to the user.

    (As an aside, parameters with leading underscores are undesirable
    as well, as they're unconventional.)
    So a simple {{#cargo_declare: tablename}}  would seem to be an
    easy solution.
    thanks/john


    On 3/31/2015 12:46 PM, Yaron Koren wrote:
    Actually, #cargo_declare follows the standard syntax for
    MediaWiki parser functions - usually, either all the parameters
    are named, or none of them are. #ask is an exception, and
    #subobject is the very rare exception where the first parameter
    is often blank (i.e., your last example).

    -Yaron

    On Tue, Mar 31, 2015 at 3:36 PM, John McClure
    <jmccl...@hypergrove.com <mailto:jmccl...@hypergrove.com>> wrote:

        The first parameter in the following syntax seems error-prone.

        {{#cargo_declare:
        _table=table name
        |field 1=field description 1
        |field 2=field description 2
        ...etc.
        }}

        Normally mediawiki parser functions are either

        {#cargo_declare: table name
        |field 1=field description 1
        |field 2=field description 2
        ...etc.
        }}

        {#cargo_declare:
        |_table=table name
        |field 1=field description 1
        |field 2=field description 2
        ...etc.
        }}

        I know/agree that{{#set}} is different.




-- WikiWorks · MediaWiki Consulting · http://wikiworks.com

-- thanks/john
    skype:hypergrove




--
WikiWorks · MediaWiki Consulting · http://wikiworks.com

--
thanks/john
skype:hypergrove
------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Semediawiki-devel mailing list
Semediawiki-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-devel

Reply via email to