I am looking to display my input validation in a div instead of an alert. I currently have
//check for COGs to be a number
if (isNaN($("#txtCOGs").val())) {
alert("The Cost of Goods Sold must be a number");
$("#txtCOGs").focus();
return false;
}
I am trying to place it in the div
<div id="divError">
Advice?
With this HTML code: