<html>
<head>
  <title> Newsletter Application Form</title>
  <script>
    function validate() {
      if (document.getElementById("txtName").value == "") {
        alert("Name must be filled out");
      }
      //else if (email == "") {
      //invalid();
      //}
    }
  </script>
</head>
<body>
  <form name="frmNews" onsubmit="validate()">
    <h2>Newsletter Application</h2>
    <p>To get our newsletters in your inbox, give us a few details
      about yourself.<br />Then tell us why you are interested in this topic in
      100 words or less.</p>
    <table>
      <tr>
        <td class="frmDetails">Name:</td>
        <td><input type="text" id="txtName" size="20" /></td>
      </tr>
      <tr>
        <td class="frmDetails">Email:</td>
        <td><input type="text" id="txtEmail" size="20" /></td>
      </tr>
      <tr>
        <td class="frmDetails">Topic:</td>
        <td>
          <input type="radio" id="radNewsletter" value="" />Health and Wellness<br />
          <input type="radio" id="radNewsletter" value="" />Creative Writing<br />
          <input type="radio" id="radNewsletter" value="" />Gardening
          <br />
        </td>
      </tr>
      <tr>
        <td class="frmDetails">I am interested in this topic because:</td>
        <td>
          <textarea id="txtTopic" cols="40" rows="5" />
          </textarea>
        </td>
      </tr>
      <tr>
        <td class="frmDetails"></td>
        <td><input type="submit" value="Submit" /></td>
      </tr>
    </table>
  </form>
  <p id="isValid"> </p>
</body>
</html>
For some reason, when I click submit, it flashes what it should onto the screen for a brief second, then it brings me to a 404 page. The problem is, my code shouldn't send me anywhere, so I have no idea what could be the issue. Any help?
I tried commenting out as much as I can, but it still brings me to the 404 when it shouldn't. I want this to not send me to a 404 while doing what it does right now.
 
    