[Seaside] Bug? calling javascript function from onComplete:

Norbert Hartl norbert at hartl.name
Tue Jul 22 12:41:52 UTC 2008


On Tue, 2008-07-22 at 09:37 -0300, Sebastian Sastre wrote:
> The empty callback "makes noise in my hears". Try making it to be either a void
> callback with the onClick defined or a useful callback without onClick but not
> the mix,
> 
That is an example!! The callback is not empty but the content
doesn't matter here ;)

Norbert
> 	cheers,
> 
> Sebastian 
> 
>  
> 
> > -----Mensaje original-----
> > De: seaside-bounces at lists.squeakfoundation.org 
> > [mailto:seaside-bounces at lists.squeakfoundation.org] En nombre 
> > de Norbert Hartl
> > Enviado el: Martes, 22 de Julio de 2008 09:22
> > Para: Seaside Mailing-List
> > Asunto: [Seaside] Bug? calling javascript function from onComplete:
> > 
> > I need to chain some calls I do with Ajax. I found
> > the onComplete:, onSuccess: etc. handlers. Every example
> > I've found in the image uses them to invoke an html updater.
> > 
> > Trying to do this
> > 
> > ... 
> >    onClick: (
> >       html updater
> >          callback: [];
> >          onComplete: 'alert("booo!");'
> >    );
> >    with: 'something'.
> > 
> > leads to javascript code like
> > 
> > new
> > Ajax.Updater('layers','http://localhost:9090/seaside/svgex',{'
> > insertion':Insertion.Bottom,'onSuccess':function(){'alert("boo
> > !");'},'evalScripts':true,'parameters':['_s=EagyxUvvWRPxlAdD',
> > '_k=K3OXE7pw','4'].join('&')})
> > 
> > The problem is that to javascript code is printed with surrounding
> > ticks ' and therefor cannot be executed.
> > 
> > Am I doing something wrong or should be work that way?
> > 
> > thanks,
> > 
> > Norbert
> >    
> > 
> > _______________________________________________
> > seaside mailing list
> > seaside at lists.squeakfoundation.org
> > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> 
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



More information about the seaside mailing list