On Jul 30, 2009, at 4:33 PM, John Small wrote: > Browsers try to be helpful and remember that when you've filled in an > input field named "email" before it's been with > "[email protected]" and they'll suggest that entry again. If > you've used many different values for a named field, then they'll > provide a drop down list of all the options you've ever used. > > Mostly very useful, but not always. In my case I don't want a long > list > of previous options to pop up in a field because it's annoying the > client. Also onchange behaves differently if you enter stuff into a > field via the keyboard compared to selecting from previously entered > values. In FF3 onChange isn't triggered if you select from previous > values, but it is if you key the data in. > > I've found a workaround, which is to give fields unique names, > either by > packing the input field name with some random chars, or something else > that's unique, like the id of an order. But that is messy, horribly > messy. There must be an easy way to do this. Maybe some param you can > set on an input field, or some javascript trick. > > Anyone have any ideas? > > Thanks > > John Small
Try adding :autocomplete => 'off' as in: <%= form.text_field :email, :autocomplete => 'off' %> and see if that doesn't do what you want. -Rob Rob Biedenharn http://agileconsultingllc.com [email protected] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" 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-talk?hl=en -~----------~----~----~----~------~----~------~--~---

