[Proto-Scripty] Re: How to insert element with value taken from attribute of parent ?

2010-08-30 Thread elivol
thank you a very much for a detailed answer ! it works fine. On Aug 30, 12:31 am, T.J. Crowder t...@crowdersoftware.com wrote: Hi, You don't want #invoke, you want #each: $$('div.item_content').each(function(div) {     div.insert({         bottom: 'input type=checkbox class=compare_itm

[Proto-Scripty] Re: How to insert element with value taken from attribute of parent ?

2010-08-29 Thread elivol
Hello Unfortunately it doesn't work: $$('div.item_content').invoke('insert', {bottom: 'input type=checkbox class=compare_itm onclick=Itm.Click(\''+ this.getAttribute('sale_num') +'\') /' }); The script fails if I put this.getAttribute('sale_num') On Aug 27, 6:55 pm, Walter Lee Davis

[Proto-Scripty] Re: How to insert element with value taken from attribute of parent ?

2010-08-29 Thread T.J. Crowder
Hi, You don't want #invoke, you want #each: $$('div.item_content').each(function(div) { div.insert({ bottom: 'input type=checkbox class=compare_itm onclick=Itm.Click(\''+ div.readAttribute('sale_num') +'\') /' }); });