title: JavaScript Error - GET http://stats.hosting24.com/count.php 404 (Not Found)
body: <p>I am making a messenger with PHP, MySQL, and JavaScript, and I'm using 000webhost.com to host it. My problem is, I get this error in the console: <code>GET http://stats.hosting24.com/count.php 404 (Not Found)</code></p>
  
  <p>Here is my index.php:</p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
      &lt;title&gt;Messenger&lt;/title&gt;
      &lt;style type="text/css"&gt;
      html {
          height: 100%;
      }
      body {
          margin: 0px;
          padding: 0px;
          height: 100%;
          font-family: Helvetica, Arial, Sans-serif;
          font-size: 14px;
      }
      .msg-container {
          width: 100%;
          height: 100%;
      }
      .header {
          width: 100%;
          height: 30px;
          border-bottom: 1px solid #CCC;
          text-align: center;
          padding: 15px 0px 5px;
          font-size: 20px;
          font-weight: normal;
      }
      .msg-area {
          height: calc(100% - 102px);
          width: 100%;
          background-color:#FFF;
          overflow-y: scroll;
      }
      .msginput {
          padding: 5px;
          margin: 10px;
          font-size: 14px;
          width: calc(100% - 20px);
          outline: none;
      }
      .bottom {
          width: 100%;
          height: 50px;
          position: fixed;
          bottom: 0px;
          border-top: 1px solid #CCC;
          background-color: #EBEBEB;
      }
      #whitebg {
          width: 100%;
          height: 100%;
          background-color: #FFF;
          overflow-y: scroll;
          opacity: 0.6;
          display: none;
          position: absolute;
          top: 0px;
          z-index: 1000;
      }
      #loginbox {
          width: 600px;
          height: 350px;
          border: 1px solid #CCC;
          background-color: #FFF;
          position: fixed;
          top: 50%;
          left: 50%;
          transform: translate(-50%, -50%);
          z-index: 1001;
          display: none;
      }
      h1 {
          padding: 0px;
          margin: 20px 0px 0px 0px;
          text-align: center;
          font-weight: normal;
      }
      button {
          background-color: #43ACEC;
          border: none;
          color: #FFF;
          font-size: 16px;
          margin: 0px auto;
          width: 150px;
      }
      .buttonp {
          width: 150px;
          margin: 0px auto;
      }
      .msg {
          margin: 10px 10px;
          background-color: #f1f0f0;
          max-width: calc(45% - 20px);
          color: #000;
          padding: 10px;
          font-size: 14px;
      }
      .msgfrom {
          background-color: #0084ff;
          color: #FFF;
          margin: 10px 10px 10px 55%;
      }
      .msgarr {
          width: 0;
          height: 0;
          border-left: 8px solid transparent;
          border-right: 8px solid transparent;
          border-bottom: 8px solid #f1f0f0;
          transform: rotate(315deg);
          margin: -12px 0px 0px 45px;
      }
      .msgarrfrom {
          border-bottom: 8px solid #0084ff;
          float: right;
          margin-right: 45px;
      }
      .msgsentby {
          color: #8C8C8C;
          font-size: 12px;
          margin: 4px 0px 0px 10px;
      }
      .msgsentbyfrom {
          float: right;
          margin-right: 12px;
      }
      &lt;/style&gt;
  &lt;/head&gt;
  &lt;body onload="checkcookie(); update();"&gt;
  &lt;div id="whitebg"&gt;&lt;/div&gt;
  &lt;div id="loginbox"&gt;
  &lt;h1&gt;Pick a username:&lt;/h1&gt;
  &lt;p&gt;&lt;input type="text" name="pickusername" id="cusername" placeholder="Pick a username" class="msginput"&gt;&lt;/p&gt;
  &lt;p class="buttonp"&gt;&lt;button onclick="chooseusername()"&gt;Choose Username&lt;/button&gt;&lt;/p&gt;
  &lt;/div&gt;
  &lt;div class="msg-container"&gt;
      &lt;div class="header"&gt;Messenger&lt;/div&gt;
      &lt;div class="msg-area" id="msg-area"&gt;&lt;/div&gt;
      &lt;div class="bottom"&gt;&lt;input type="text" name="msginput" class="msginput" id="msginput" onkeydown="if (event.keyCode == 13) sendmsg()" value="" placeholder="Enter your message here ... (Press enter to send message)"&gt;&lt;/div&gt;
  &lt;/div&gt;
  &lt;script type="text/javascript"&gt;
  
    var msginput = document.getElementById("msginput");
  
    function showLogin() {
      document.getElementById("whitebg").style.display = "inline-block";
      document.getElementById("loginbox").style.display = "inline-block";
    }
  
    function chooseusername() {
      var user = document.getElementById("cusername").value;
      document.cookie = "messengerUname" + user;
      checkcookie();
    }
  
    function checkcookie() {
      if(document.cookie.indexOf("messageUname") == -1) {
        showLogin();
      } else {
        hideLogin();
      }
    }
  
    function getcookie(cname) {
      var name = cname + "=";
      var ca = document.cookie.split(';');
      for(var i=0; i&lt;ca.length; i++) {
          var c = ca[i];
          while (c.charAt(0)==' ') c = c.substring(1);
          if (c.indexOf(name) == 0) return c.substring(name.length,c.length);
      }
      return "";
    }
  
    function sendmsg() {
      var message = msginput.value;
      if(message != "") {
  
        var username = getcookie("messengerUname");
  
        var xmlhttp = new XMLHttpRequest();
  
        xmlhttp.onreadystatechange = function() {
          if(xmlhttp.readyState == 4 &amp;&amp; xmlhttp.status == 200){
            console.log(xmlhttp.responseText);
                  }
        }
  
          xmlhttp.open("GET","devconnect.comxa.com/update-messages.php?username="+username+"&amp;message="+message, true);
          xmlhttp.send();
          }
      }
  &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>You can see the website and error <a href="http://devconnect.comxa.com" rel="nofollow">here</a> (The error is in the console)</p>
  
  <p>I get another error, <code>Uncaught ReferenceError: update is not defined</code>, but I know why, so that error is fine.</p>