new Element('input#item_id[type=text]') should work fine in MooTools 1.3. If
you're still using 1.2 you can add those attributes to the attributes
object.The item[] do increment, when sending it to the server it will actually become an array. On Sun, Dec 19, 2010 at 8:01 PM, lidgold <[email protected]> wrote: > Hello, > thanks for you reply. > > I think there's a little problem with this part of the script > > input#item_id[type=text] > > I've got it working this way > > document.addEvent( 'domready' , function() { > > $('addRow').addEvent('click', function() { > new Element('tr').adopt( > new Element('td').adopt(new Element('input', {name: > 'item[][item_id]'})), > new Element('td').adopt(new Element('input', {name: > 'item[][item_name]'})) > ).injectInside('myTbody'); > }); > }); > > Anyway the item number [] does not increment. > > What do you think about? > > Thank you >
