Cordova App: CANNOT GET /www/html/filename.html
<p>My splash.js file outputs "CANNOT GET /www/html/login.html" which is the page it redirects to when it is tested on the ripple emulator. But running it on my device gets it to work. Wanted to reduce build time since testing it on the emulator is much faster compared to my phone.</p>

<p>splash.js Javascript code: </p>

<pre><code>$(document).ready(function () {
    swal({
        title: "Hi!",
        text: "Welcome to FarmVille",
        imageUrl: "../www/images/ring-alt.gif",
        showConfirmButton: false,
    });
    var xmlhttp = new XMLHttpRequest();
    xmlhttp.onreadystatechange = function () {
        if (this.readyState == 4 &amp;&amp; this.status == 200) {
            if (this.responseText == "success") {
                setTimeout(function () {                            //page redirect after 2 seconds.
                    window.location.href = "../www/html/login.html";
                }, 2000);
            } else {
                sweetAlert("Oops...", "There was an error connecting, try again!", "error");
                document.getElementById("password").value = "";
            }
        }
    }
    xmlhttp.open("GET", "http://www.sampleee.esy.es/checkdbconnection.php", true);
    xmlhttp.send();
});
</code></pre>