Can I treat radio buttons the same as other fields in my form for the
purposes of jquery script
Can I use
$("#example").change(function(e)
if (e.target.value=='Yes')
...
Or do I have to use a different method?
--
You received this message because you are subscribed to the Google Groups "
is this a better way to check for empty form field inputs than trim and val
combined?
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonrails-talk+un
That's not what #any? is for, but it is a common misconception. Try running
the code I suggested you run, and read the docs I suggested you read to see
why. To be more clear, try running this - `[false].any?` and
`[false].empty?` and see if you get what you expect.
On Apr 1, 2017 8:44 AM, "Leandro
Hey Scott,
You're absolutely right. If we want to ask an array if it is empty, we can
use the *.empty?* method. But if we want to ask if the array has *any*thing
inside it, we can use *.any?* method :)
On Saturday, April 1, 2017 at 10:41:01 AM UTC-3, Scott Jacobsen wrote:
>
> Nice post. But y
Nice post. But you shouldn't use any? to test if a collection is empty. To
see why try it on this array: [nil, false] and read the docs. Use empty? to
test if an array is empty.
On Apr 1, 2017 12:02 AM, "Leandro TK" wrote:
> Hello guys,
>
>
> As all of you, I think Ruby a beautiful programming l
jquery seems to work in layout but on forms not hiding elements; how can i
get help with this when my code is html.erb
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, sen
jquery seems
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonrails-talk+unsubscr...@googlegroups.com.
To post to this group, send email to rubyonra
7 matches
Mail list logo