Re: .down with inputs named as array

louis w
Mon, 16 Jun 2008 21:17:42 -0000

This works. Thanks.

On Jun 13, 1:44 pm, kangax
<kan...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:
> Wrap attribute value in quotes.
> Also, it''s a good idea to define variables local:
>
> var prop = ''fields[title]'';
> $(''foo'').down(''[name="''+ prop
+''"]'');
>
> - kangax
>
> On Jun 13, 1:13 pm, louis w
<louiswa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
> > Having problems using the down function to find inputs which have been
> > named as an array.
>
> > Example:
> >
> >     <input type="text"
name="fields[title]"/>
>
> > prop = ''fields[title]'';
> > $(''foo'').down(''[name=''+ prop
+'']'');
>
> > This is related to this
posthttp://groups.google.com/group/rubyonrails-spinoffs/browse_thread/thr...