yes.

instead of

  form[0][2][2].insert(0,...)

use

  form.element('#table_field__row TD.w2p_fc').insert(0,...)

Not sure it is easier in this case.

  table_field__row is the id of the row for table.field
  w2p_fc is the class name of the comment column.

Massimo

On Jan 4, 11:32 am, Jonathan Lundell <[email protected]> wrote:
> On Jan 4, 2011, at 8:26 AM, mdipierro wrote:
>
>
>
> > We have that
>
> > form.element(...)
> > form.elements(...)
>
> > both take jQuery syntax.
>
> So the construction below can be expressed that way?
>
>
>
> > Massimo
>
> > On Jan 4, 10:13 am, Jonathan Lundell <[email protected]> wrote:
> >> On Jan 4, 2011, at 7:19 AM, annet wrote:
>
> >>> Thanks for your reply. I tried:
>
> >>> form[0][2][2].insert(0,A('already in
> >>> database?',_onmouseover="this.style.cursor='pointer';",_onclick="javascript:details('%s/'+
> >>> $('#kvk_number').val()+'/'+$
> >>> ('#subdossiernumber').val())"%URL(r=request,f='retrieve')))
>
> >> Wouldn't it be cool to have a systematic way of working with forms? A kind 
> >> of DOM, with jQuery-like syntax for talking about specific components? 
> >> Constructions like form[0][2][2].insert(0,… are impossibly opaque.
>
>

Reply via email to