Err Posted March 29, 2010 Share Posted March 29, 2010 I'm trying edit a value on a table cell through AJAX. I want to know if there is a way to make the script automatically detect which table and table cell is double clicked. table 1 cell cell cell table 2 cell cell <- I want the script to know where this table is and what table cell it is. cell The usual way I would do it is put handlers on the function when it's called, something like: togEdit(2,2) where 2 is table 2, and the next 2 is table cell 2. Is there a way to do this? Some examples and some links would really help. Link to comment Share on other sites More sharing options...
justsomeguy Posted March 29, 2010 Share Posted March 29, 2010 You should be able to access the element which was clicked on through the event handler, and use the DOM to access the element's parents to see which containers it's in. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.