From c368346464e852f0f5d7ef9efee6107692a34439 Mon Sep 17 00:00:00 2001 From: Long Nguyen Date: Fri, 27 Sep 2024 15:11:41 +0700 Subject: [PATCH] avoid spam --- templates/template135/js/script.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/template135/js/script.js b/templates/template135/js/script.js index c968637..44cae9e 100644 --- a/templates/template135/js/script.js +++ b/templates/template135/js/script.js @@ -104,6 +104,7 @@ // Collect form data var name = $('#name-comment').val(); var content = $('#detail-comment').val(); + $('#btn-submit-comment').attr("disabled", true); $.ajax({ type: "POST", url: "https://script.google.com/macros/s/AKfycbyjSlC6ymLR8fasKqCIVA8CNsX5NvqfQs019drdtpqnUfe375uHi70NBdZUqQrbBErEMw/exec", @@ -129,6 +130,7 @@ } form.reset(); + $('#btn-submit-comment').attr("disabled", false); }, error: function() { $( "#loader").hide();