[Seaside] callback registry
Marco D'Ambros
marco.dambros at lu.unisi.ch
Wed Oct 29 07:57:54 UTC 2008
Hi,
I tried to insert the script in a seaside application, in the
#updateRoot: method like this:
updateRoot: root
super updateRoot: root.
root javascript resourceUrl: 'http://www.prototypejs.org/assets/2008/9/29/prototype-1.6.0.3.js'
.
root javascript add: '$(document.body).observe("click", function
(event) {
var element = Event.element(event);
var extractor = /]*>((.|\s)*)<\/body>/;
if (!element.href) element = element.up("a");
if (element.href) {
new Ajax.Request(element.href, {
method: "get",
requestHeaders: [ "X-Requested-With", "" ],
onSuccess: function (transport) {
document.body.innerHTML =
extractor.exec(transport.responseText)[1];
}
});
Event.stop(event);
}
}.bindAsEventListener());'
but it seems that I did not succeed.
Am I doing something wrong?
Cheers and thanks
Marco
On Oct 24, 2008, at 8:42 PM, Lukas Renggli wrote:
>> thanks for the reply. Could you please tell me a bit more about the
>> details,
>> especially on the client-side javascript?
>
> http://www.lukas-renggli.ch/blog/ajaxification
>
> Cheers,
> Lukas
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
More information about the seaside
mailing list