Subversion Repositories DevTools

Rev

Rev 6616 | Rev 6651 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6616 Rev 6617
Line 62... Line 62...
62
 
62
 
63
//stateChangeHandler will fire when the state has changed, i.e. data is received back
63
//stateChangeHandler will fire when the state has changed, i.e. data is received back
64
// This is non-blocking (asynchronous)
64
// This is non-blocking (asynchronous)
65
function stateChangeHandler()
65
function stateChangeHandler()
66
{
66
{
67
	
67
    var str;
68
    //readyState of 4 or 'complete' represents that data has been returned
68
    //readyState of 4 or 'complete' represents that data has been returned
69
    if (xmlHttp.readyState == 4 || xmlHttp.readyState == 'complete'){
69
    if (xmlHttp.readyState == 4 || xmlHttp.readyState == 'complete'){
-
 
70
        if ( xmlHttp.status != 200 ) {
-
 
71
            // Generate an error message
-
 
72
            str = "Ajax Load Error [" + xmlHttp.status + ']: ' + xmlHttp.statusText + '<br>Url:' + xmlHttp.responseURL;
-
 
73
        } else {
70
        //Gather the results from the callback
74
            //Gather the results from the callback
71
        var str = xmlHttp.responseText;
75
            str = xmlHttp.responseText;
-
 
76
        }
72
 
77
 
73
        //Populate the innerHTML of the div with the results
78
        //Populate the innerHTML of the div with the results
74
		MM_findObj( ajaxdivname ).innerHTML = str;
79
		MM_findObj( ajaxdivname ).innerHTML = str;
75
    }
80
    }
76
}
81
}