Re: How can I change default AJAX settings?

Paul DeBruicker <[email protected]>
Newsgroups gmane.comp.lang.smalltalk.squeak.seaside
Message-ID <[email protected]>
At the bottom of the page in the footer I have this: 



html document
    addLoadScript:
      (html jQuery document
        onAjaxSend: (html jQuery class: 'spinner') show;
        onAjaxComplete: (html jQuery class: 'spinner') hide;
        onAjaxError:
            (self ajaxErrorHandler asFunction: #('event' 'jqxhr' 'settings'
'exception')))


So I think all you're missing is the #document send in there.  




Also on a case by case basis you can use POST rather than GET if you do a


html textInput
   onChange: html jQuery post serializeThis;
   on: #mvVar of: self.


I'm not sure of the trade-offs of using POST all the time vs GET but I think
for Seaside it won't hurt.  Probably :)





Mariano Martinez Peck wrote
> Hi guys,
> 
> I have a few places where I am reaching the limit of URL size due to AJAX
> serialziation. I can manually fix the places where I serialize a bunch and
> do:
> 
> jQuery ajax type: 'POST';
> serializeForm;
> ...
> 
> But I am wondering if I can change this globally, for all AJAX requests. I
> tried this:
> 
>  html jQuery ajaxSetup type: 'POST'
> 
> But doesn't seem to work. Does someone know how to?
> 
> In addition, I wonder, is it a bad idea to set 'POST' as default?
> 
> Thanks in advance,
> 
> 
> -- 
> Mariano
> http://marianopeck.wordpress.com
> 
> _______________________________________________
> seaside mailing list

> [email protected]

> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside





--
View this message in context: http://forum.world.st/How-can-I-change-default-AJAX-settings-tp4942023p4942164.html
Sent from the Seaside General mailing list archive at Nabble.com.
_______________________________________________
seaside mailing list
[email protected]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.