jquery - how to open a dialog box after clicking a table row and edit -


I want to apply a dialog box which will open as soon as I click on a table row. Basically the database is edited through table rows, the table contents are stored in the database and received from there. If I edit the line then the database should be automatically updated. When I click on the line, the dialog box will receive some special cells from the row and I'll modify it or delete the row and should be visible immediately in the results table. I want to jquery it through AJAX, after opening the dialog box, Ajax should call the servlet and modify the database. Please also give the code.

  & lt; Fieldet id = "alltweets" & gt; & Lt; Table cells = "20" square = "tweet table" & gt; & Lt; Title & gt; Tweets & lt; / Heading & gt; & Lt;% while (rsnext ()) {%> & Lt; Tr id = "ForChangingTweet" & gt; & Lt; TD & gt; & Lt;% = rs.getString (1)%> & Lt; / TD & gt; & Lt; TD & gt; & Lt;% = rs.getString (2)%> & Lt; / TD & gt; & Lt; TD & gt; & Lt;% = rs.getString (3)%> & Lt; / TD & gt; & Lt; / TR & gt; & Lt;%}% & gt; & Lt; / Table & gt; & Lt; / Fieldset & gt; Click (function () {$ ("# dialog"). Dialog ({autoOpen: true, model: true, width: 600, height: 300, resizable: wrong, button: {"yes!": Function ) {$ (This) .dialog ("closed");}, "sure, why not": function () {$ (this) .dialog ("close");}}}) $ .aax ({type : "Post", url: "changetites", data: {notifyidd: $ (this) .attr ("i d")}, error: work () {alert ('error');}, success: function ) {Alert ('success');}});});  

I have also added some JS files

   

The last two are my goals in each row

  & lt; Tr id = "ForChangingTweet" & gt;  

to

  & lt; Tr class = "ForChangingTweet" & gt; Use $ ('.changingTweet') to use TR and $ because $ ('ForChangingTweet') can get only one ID in the DOM. 


Comments

Popular posts from this blog

Member with no value in F# -

java - Joda Time Interval Not returning what I expect -

c# - Showing a SelectedItem's Property -