Specifying multiple for select


#1

With select(), how can I get it to just add ‘multiple’
to the tag? Here’s what I’m doing:

select ‘obj’, ‘prop’, collection, {},
{:multiple=>true, :size=>10}

which outputs:

I’d like it to look like this:

Possible?

thanks
csn


Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com


#2

On 11/12/2005, at 11:48 PM, CSN wrote:

I’d like it to look like this:

Possible?

What’s wrong with multiple=“multiple”? It’s perfectly valid.


Phillip H.
removed_email_address@domain.invalid


#3

— Phillip H. removed_email_address@domain.invalid
wrote:

which outputs:

I’d like it to look like this:

Possible?

What’s wrong with multiple=“multiple”? It’s
perfectly valid.

Uh, because the spec says ‘multiple’ not
‘multiple=“multiple”’.

csn

http://lists.rubyonrails.org/mailman/listinfo/rails


Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com


#4

CSN wrote:

— Phillip H. removed_email_address@domain.invalid
wrote:

which outputs:

I’d like it to look like this:

Possible?

What’s wrong with multiple=“multiple”? It’s
perfectly valid.

Uh, because the spec says ‘multiple’ not
‘multiple=“multiple”’.

‘multiple’ is no valid X(HT)ML. Every attribute must have a value.


#5

On 12/12/2005, at 8:27 AM, CSN wrote:

Uh, because the spec says ‘multiple’ not
‘multiple=“multiple”’.

It’s not valid XHTML. HTML 3 maybe, but all HTML parsers will accept
multiple=“multiple”, plus you get XHTML compliance should you need
it. Who looses here?


Phillip H.
removed_email_address@domain.invalid


#6

is valid HTML 4.01:
http://www.w3.org/TR/html4/interact/forms.html#h-17.6

But you two are correct, attributes must have values
in XHTML:
http://www.w3.org/TR/xhtml1/#h-4.4

Well, as long as browsers can handle
‘multiple=“multiple”’ and ‘selected=“selected”’ (which
at least my Firefox and IE can)…

csn


Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com