title: Unexpected token >
body: <p>The script used to work before, now it suddenly doesnt. It returns a unexpected token > error which makes no sense cause I haven't edited anything here, but when removing the other code I added it still doesn't work. And the button doesn't trigger the code now after I tried fixing it, but that's another problem. Can you guys see why?</p>
  
  <pre><code>function dologin() {
      var senddata = $('#form').serialize();
  
      $.ajax({
          type: 'post',
          url: 'herpaderp',
          data: senddata,
          crossDomain: true,
          dataType: 'json',
          success: function (response) {
              if (response.success == true)
                  window.location.href = "herpderp";
              else if (response.success == false)
                  navigator.notification.alert("Feil brukernavn eller passord", null, "Mislykket innlogging", "OK");
              else
                  alert("Noe gikk galt, kontakt administrator");
          },
          error: function (XMLHttpRequest, textStatus, errorThrown) {
              console.log("Status: " + textStatus);
              console.log("Error: " + errorThrown);
          }
      });
      return false;
  };
  </code></pre>