Hi,

            I'm using Builder.node to create a table dynamically . My
table has a horizontal rule(first Row) , headers (second row) and
followed by a horizontal rule (thrid Row) again. Following is the code
I used to generate the table.



            var tbody = Builder.node('tbody');

var rowOne = Builder.node('tr',[

                    Builder.node('td',{colSpan:'6'},[

                        Builder.node('hr')

                    ])

                ]);

            var rowTwo = Builder.node('tr',{className:'tablehead'});

            tbody.appendChild(rowOne);

tbody.appendChild(rowTwo);

tbody.appendChild(rowOne);  // didn't work.



The above code created only one horizontal rule ,down below the
headers.

To make this work,I created another variable which is a exact copy of
rowOne and then added to tbody as tbody.appendChild(rowThree).

can't we use the same variable name to add it to the tbody?


--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to