That's a good point. I'm actually wary of using a multi select that's
been hidden from previous experiences with how web browsers handle it,
otherwise I definitely would have.

On Oct 21, 10:12 am, weheh <[email protected]> wrote:
> Web2py uses multi SELECT widget for list:string fields. You can hide
> the multi SELECT by setting its style to { display: none; }. You can
> do it with an input field, too. But if you want to be exactly like
> web2py, do it with a SELECT.
>
> On Oct 21, 12:19 am, Chris <[email protected]> wrote:
>
>
>
> > This code is a hybrid that will let you use a hidden control while
> > messing about with it in your own HTML/XML:
>
> > def day_selector_widget(field, value):
> >     xml_stuff = XML(response.render("widgets/
> > day_selector.html",
> >                                _id = str(field).replace('.','_'))
> >                             )
> >     return DIV(
> >              INPUT(
> >                _type = 'hidden',
> >                _id = str(field).replace('.','_'),
> >                _name=field.name,
> >                _value="|".join(value)), xml_stuff)
>
> > On Oct 20, 11:36 pm, Chris <[email protected]> wrote:
>
> > > Thanks. While I'd like to do that, I can't here, because I'm doing a
> > > custom input scheme with a different UI. That does give me an idea
> > > though. I'll try and copy the POST a SELECT multiple would send.
>
> > > On Oct 20, 11:29 pm, weheh <[email protected]> wrote:
>
> > > > Oh, and don't forget to make SELECT(..., _multiple='multiple', ...)

Reply via email to