On Tuesday 27 January 2004 02:30 am, Kjetil Kjernsmo wrote:
> But it doesn't do all I wanted, at least not straightforwardly. I want them
> all! :-) That is, a list of all parameters for a name. With the two
> additions, I guess you could do that with a loop, but then, I have this
> something against mixing in Perl... In the interest of backwards
> compatability and maintaining relative simplicity, I guess it is best to
> keep that element like it is... :-)

Hmm...okay.  So, you wanna take perl completely out of the picture.

> May I suggest an element, something like
> <param:get-all name="foo"/>
> that if given the query ?foo=bar&foo=baz
> will return
> <value>bar</value>
> <value>baz</value>

So I gather you're going to be post-processing this?

> Possibly, the name of the element (instead of 'value') could be an
> attribute too, and perhaps an optional element around these...

Actually, I added an optional "name" attribute to "enumerate", so you could 
say:

<param:enumerate name="foo"/>

> > =head2 C<<param:count name="foo"/>>
> >
> > Returns the number of parameters provided on the request.  If a name is
> > provided, the number of parameters supplied for the given name is
> > returned. If the name is left out, then the total number of parameters is
> > returned.
>
> Hm, this returned 1 on me if I used multiple parameters with the same name.
> With different parameters, and no name attribute, it was correct. I'll try
> to look more about what could be the matter with that later (gotta run now
> (quite literally)).

Okay, this should be fixed.  The latest version is in CVS.  Try it, test it, 
and let me know how it worked out.

> > This code is *completely* untested, since my development server has been
> > taken by my SysAdmin for some emergency server replacement work,
>
> Uhm, that's life... :-) I don't even have a separate development server (so
> I do most work on my workstation, and upload when I want others to have a
> look).

One of the nice things about using AxKit as a central part of your company's 
business is that you get good servers to develop on.  One of the downsides of 
the same, is that now everyone relies on it, which means you can no longer do 
ad-hoc code changes, or you'll *instantly* hear everyone groan "SCAMP's 
down!"  *sigh*

You know, it occurs to me that this would be well-suited to the axkit-devel 
mailing list.  Oh well.

-- 
/* Michael A. Nachbaur <[EMAIL PROTECTED]>
 * http://nachbaur.com/pgpkey.asc
 */

"Anyone who is capable of getting themselves made President 
should on no account be allowed to do the job." 

-- Some wisdom from The Book. 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to