on lines 1 and 3 I put alerts - I'm confused as where the res variable
in the function comes from - since res does not exist before the
function in the code how can it be a variable in the function?
You're giving jQuery.ajax() a callback function as the 4th arg. When
that function is called
This sample helps you?
http://pepper.sherry.jp/jquery/newajaxfunc2.html
$().load() / $().get() / $.().post() callback's 2nd argument shows status.
If status == 'success', ajax request succeeded.
If status == 'error', ajax request failed. (because file not found,
timeout, etc.)
When
Still working on the GetIfModified as outlined here:
http://www.mail-archive.com/discuss@jquery.com/msg00481.html
Any examples of how to use this properly? I'm not sure how to grab the
states success, failure, notomdified etc.
will
___
jQuery
Well with HTTP codes, i know that code 200 is success.. thats about it..On 8/29/06, Will Jessup [EMAIL PROTECTED]
wrote:Still working on the GetIfModified as outlined here:
http://www.mail-archive.com/discuss@jquery.com/msg00481.htmlAny examples of how to use this properly? I'm not sure how to
On 8/29/06, Will Jessup [EMAIL PROTECTED] wrote:
Matt,Hehe. well jQuery has quite a bit of cool code I just can't seem to getit to work.Firstly it seem the functions $.ajaxStart, $.ajaxComplete etc. areattached globally and triggered when they should be,
2nd it says that there is a 2nd variable
Shawn ,
Ah so obvious now, thx.
Will
On 8/29/06, *Will Jessup* [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:
Matt,
Hehe. well jQuery has quite a bit of cool code I just can't seem
to get
it to work.
Firstly it seem the functions $.ajaxStart, $.ajaxComplete etc.
Can anyone decode this for me -
alert(res) //null
jQuery.ajax( type, url, params,function(res, status){
alert(res) // contains the response code
if ( status == success || !ifModified status ==
notmodified ) {
// Inject the HTML into all the matched elements