task_name only word

This commit is contained in:
Ramadhon Ikhsan Prasetya 2024-12-10 16:40:10 +07:00
parent 2f08a4c0ce
commit bed287ba35
2 changed files with 7 additions and 1 deletions

View File

@ -246,6 +246,12 @@
setInterval(setTime, 1000);
})
function invalidSymbol() {
var str = document.getElementById("judul_");
var regex = /[^a-z]/gi;
str.value = str.value.replace(regex ,"");
}
function checkTime(i) {
if (i<10) {i = "0" + i}; // add zero in front of numbers < 10
return i;

View File

@ -14,7 +14,7 @@
<div class="form-group row mt-5">
<label class="col-form-label col-xl-4 text-center" style="color: #8a2727;">Judul</label>
<div class="col-xl-8">
<input type="text" name="judul_" id="judul_" class="form-control form-control-sm" value="">
<input type="text" onkeyup="invalidSymbol()" onkeydown="invalidSymbol()" name="judul_" id="judul_" class="form-control form-control-sm" value="">
</div>
</div>
<div class="form-group row">