This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JS inside innerHtml

 
Arya Devan
Greenhorn
Posts: 28
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ..

how can i call a javascript function inside innerHtml.

My situation goes like this. I have a table that has 4 columns. When i hit enter on the 3rd column a new row has to be created dynamically. I use innerHtml for the same. Now, i need to know how can i call another javascript function in that newly created row/column .. like ondblclick() or any other function on that 3rd column.
 
Tina Desai
Ranch Hand
Posts: 365
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You must be knowing the function name when you are generating the row.
In the code to generate the row, you can specify the function name
Something like the following:



Regards,
Tina
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic