For some reason I got stuck with this 'thing'
As you can see I want to try to read the count.txt. This is working perfectly but for some reason the
alert(code);
is coming up after the
alert("The number can't be smaler then 0");
For me it makes no sense because I'd call the alert(count) before the alert("The number...") Any ideas why the jQuery function (alert) is called after the other alert?
function leftFunction() {
    jQuery.get('count.txt', function(data) {
        var count = data;
        alert(count);
    });
    scrolling = true;
    if(number == 0) {
        alert("The number can't be smaler then 0");
        return;
    }
    number--;
    document.getElementById("myImage").src = "latest" + number + ".jpg";
}