On Mar 22, 6:28 am, "jko170" <[EMAIL PROTECTED]> wrote:
> Okay, in Firefox it resets the select box just as intended. But in
> Safari it does nothing to the select box. Is this a known bug and is
> there a workaround?

If no option has the selected attribute set, Safari doesn't reset the
options.  Set the selected attribute for the option you want to be the
default selected (usually the first one) in the HTML source or however
you create the options:

  <select ... >
    <option selected ... >
    <option ... >
    ...

You are supposed to do that anyway, but no one ever does.

<URL: http://www.w3.org/TR/html4/interact/forms.html#idx-menu-2 >


"If no OPTION element has the selected attribute set, user agent
behavior for choosing which option is initially selected is undefined.
Note. Since existing implementations handle this case differently, the
current specification differs from RFC 1866 ([RFC1866] section 8.1.3),
which states:

 "The initial state has the first option selected, unless a
   SELECTED attribute is present on any of the <OPTION>
   elements.

"Since user agent behavior differs, authors should ensure that each
menu includes a default pre-selected OPTION."


--
Rob


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to