Welcome aboard! We are happy you are here and wish you good net-raft!
<!DOCTYPE html>
<html lang="en">
<head>
<script src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
<script>
$(document).ready(function(){
$("button").click(function(){
if(!$("input").val()){
alert("empty");
} else{
alert("not empty");
}
});
});
</script>
</head>
<body>
<input type="text">
<p></p>
<button type="button">check</button>
</body>
</html>
The most helpful JQUERY solutions