title: JQuery undo append
body: <p>I've got a table with a button inside a td, once I press the button it adds text to the td. I want to remove this text inside the td once i press the button again. note that <strong>this button is used multiple times in the table</strong> hence the class attribute.
  Which method could I use to get this done?</p>
  
  <p>This is my code:</p>
  
  <pre><code>$(document).on('click', '.releasebutton', function () { // button class="releasebutton"
      var label = $(this).text();
      if (label == "Add") { // it is "Add" by default
          $(this).text("Cancel");
          $('.ReleaseTD').append("&lt;br&gt;" + "test"); // td class="ReleaseTD"
      }
      // the code above this works
      else {
          $(this).text("Add");
          $('.ReleaseTD').remove("&lt;br&gt;" + "test"); 
          // this obviously is wrong but this is where i would like the correct code
      };
  });
  </code></pre>