php - JQuery adds unwanted div after an ajax call -
i have jquery ajax call add new comment database. saves fine when want reaload div comments shown, additional div not want. when reaload page fine , displayed wanted! the script: <script> $("#addcmt").click(function() { var userid = $("#userid").val(); var classid = $("#classid").val(); var text = $("#appendedinputbutton").val(); var option; if($("#option").is(':checked')) { option = 3; } else { option = 1; } $.ajax({ type: "get", url: "/comment/functions/add_class_comment.php", data: "text=" + text + "&userid=" + userid + "&classid=" + classid + "&option=" + option, success: function(msg) { $("#commentlist").load(loc...