You can add custom attributes to $.ajax's object (thus to ajaxSetup).
'data' is likely to misbehave behave that value is sent to the server,
and in some cases it has to be forcedly set to null to avoid sending
both POST and GET vars.

If you use any other key, it should work alright.

As a sidenote, your specific example seems pointless. Because you're
setting mydata each time before calling $.ajax, so you can simply add
it to $.ajax.

--
Ariel Flesler
http://flesler.blogspot.com

On Sep 21, 11:26 am, "sui-sing Lai" <[EMAIL PROTECTED]> wrote:
> ok, I tried to pass "this" object to ajax callback.
> I refer to jQuery doc and find out that I can pass it to via
> $.ajaxSetup( { mydata : this } ).
> code go like this:
>
> var myObj = function() {
>   $.ajaxSetup({mydata:this});
>   $.ajax({
>     ....
>     success:function(xml){ this.mydata.status = 200}
>   }
>
> }
>
> Hope this is better.
>
> Thanks,
> sglai
>
> 2008/9/21 Jörn Zaefferer <[EMAIL PROTECTED]>:
>
> > Could you be more specific about the actual issue?
> > $.ajaxSetup({mydata:this}) doesn't make much sense.
>
> > Jörn
>
> > On Sun, Sep 21, 2008 at 10:58 AM, sglai <[EMAIL PROTECTED]> wrote:
>
> >> Hi,
>
> >> Happen to find this problem. Does release test case cover this?
>
> >> Regards,
> >> sglai
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to