There are sending messages. It works, but when I send a message, the text in the diva remains. How to make it so that when you click on the "send" button in the input box, the text is deleted. Text before sending

By clicking the text remains in the input field

  • four
    Code, show your code and your attempts, not screenshots. - Duck Learns to Take Cover

1 answer 1

$('.MyButton').on('click', function() { $("div.MyInput").html(""); }); 
  • one
    .empty() for this is - Artem Gorlachev