Entire html stream in span after html updater

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Entire html stream in span after html updater

Mart-Mari Breedt
Hi,

Maybe somebody knows of a possible reason why an html updater would put
the entire html page contents in the span that is being updated? I have
this scenario where the updater works fine in the one instance, but when
I use the same updater in a slightly different context it places the
entire web page in the span that needs to be updated. I did check for
any passing of the html stream to the rendering block and not the local
renderer by mistake and it all seems fine. Is there something else I can
check for perhaps?

Thank you,

Mart-Mari


_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: Entire html stream in span after html updater

Mart-Mari Breedt
This one is very bizarre! On the one form where the updater worked as
expected, I didn't have a submit button, but on the other form I had
one. When I removed my submit button on the second form, it also worked
as expected. Does anyone maybe know why this is?

Thank you,

Mart-Mari

-----Original Message-----
From: Mart-Mari Breedt
Sent: 14 Augustus 2006 12:52 nm
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: [Seaside] Entire html stream in span after html updater

Hi,

Maybe somebody knows of a possible reason why an html updater would put
the entire html page contents in the span that is being updated? I have
this scenario where the updater works fine in the one instance, but when
I use the same updater in a slightly different context it places the
entire web page in the span that needs to be updated. I did check for
any passing of the html stream to the rendering block and not the local
renderer by mistake and it all seems fine. Is there something else I can
check for perhaps?

Thank you,

Mart-Mari


_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: RE: Entire html stream in span after html updater

Lukas Renggli
> This one is very bizarre! On the one form where the updater worked as
> expected, I didn't have a submit button, but on the other form I had
> one. When I removed my submit button on the second form, it also worked
> as expected. Does anyone maybe know why this is?

Could you publish a small example where I can reproduce this?

Cheers,
Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: RE: Entire html stream in span after html updater

Mart-Mari Breedt
In reply to this post by Mart-Mari Breedt
Hi Lukas,

Please find a small example attached. In UpdaterTest1 you can select
between Characters and Integers and when you add any of these two, it
adds it to the list. In UpdaterTest2 (that inherits from UpdaterTest1) I
just added a submit button. When selecting characters or integers to add
to the list in the second version, the entire html content is returned.

Hope this can help clear things out.

Thanks,

Mart-Mari

-----Original Message-----
From: Lukas Renggli [mailto:[hidden email]]
Sent: 14 Augustus 2006 01:40 nm
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: Re: RE: [Seaside] Entire html stream in span after html updater

> This one is very bizarre! On the one form where the updater worked as
> expected, I didn't have a submit button, but on the other form I had
> one. When I removed my submit button on the second form, it also
worked
> as expected. Does anyone maybe know why this is?

Could you publish a small example where I can reproduce this?

Cheers,
Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

UpdaterTest2.st (538 bytes) Download Attachment
UpdaterTest1.st (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: RE: RE: Entire html stream in span after html updater

Lukas Renggli
Hi Mart-Mari,

> Please find a small example attached. In UpdaterTest1 you can select
> between Characters and Integers and when you add any of these two, it
> adds it to the list. In UpdaterTest2 (that inherits from UpdaterTest1) I
> just added a submit button. When selecting characters or integers to add
> to the list in the second version, the entire html content is returned.

the problem with the attached code is that the JavaScript part of
script.aculo.us is triggering the button callback. This causes Seaside
to abort further callback processing and restart the rendering loop
with a full page render.

Now what can we do about this?

Choose one of these options:

- Instead of triggering the whole form you could just trigger the form
elements you require, in your case the changed select box.

- Change the JavaScript of script.aculo.us not to trigger submit buttons.

- Change the way Seaside processes action-callbacks, this means to
ignore all action callbacks with script.aculo.us requests. This is
quite a deep change to Seaside, so maybe we should rethink that.

Cheers,
Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Simple link->app

Kurt Thams
Okay...this has got to be one of the simplest things but I just can't figure
it out.

How do make a link (or button) in one WAComponent that, when clicked, brings
up a different WAComponent?



_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Simple link->app

keith1y
Kurt,

I am not an expert but you might try something like

html anchor callback: [  self call: WAMyComponent new ] ; text: 'My
Component'.

or

html form: [ html submitButton callback:  [ self call: WAMyComponent new
]; text: 'MyComponent ]


Keith

               
___________________________________________________________
All New Yahoo! Mail – Tired of Vi@gr@! come-ons? Let our SpamGuard protect you. http://uk.docs.yahoo.com/nowyoucan.html
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: RE: Entire html stream in span after html updater

Sophie424
In reply to this post by Mart-Mari Breedt
I have seen something like this too, and assumed I was doing something wrong
(which I may well have been doing as well :-)

Cheers.

----- Original Message -----
From: "Mart-Mari Breedt" <[hidden email]>
To: "The Squeak Enterprise Aubergines Server - general discussion."
<[hidden email]>
Sent: Monday, August 14, 2006 7:55 AM
Subject: RE: RE: [Seaside] Entire html stream in span after html updater


Hi Lukas,

Please find a small example attached. In UpdaterTest1 you can select
between Characters and Integers and when you add any of these two, it
adds it to the list. In UpdaterTest2 (that inherits from UpdaterTest1) I
just added a submit button. When selecting characters or integers to add
to the list in the second version, the entire html content is returned.

Hope this can help clear things out.

Thanks,

Mart-Mari

-----Original Message-----
From: Lukas Renggli [mailto:[hidden email]]
Sent: 14 Augustus 2006 01:40 nm
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: Re: RE: [Seaside] Entire html stream in span after html updater

> This one is very bizarre! On the one form where the updater worked as
> expected, I didn't have a submit button, but on the other form I had
> one. When I removed my submit button on the second form, it also
worked
> as expected. Does anyone maybe know why this is?

Could you publish a small example where I can reproduce this?

Cheers,
Lukas


_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

RE: RE: RE: Entire html stream in span after html updater

Mart-Mari Breedt
In reply to this post by Mart-Mari Breedt
Hi Lukas,

Thank you for your response. The problem seems less bizarre now :-).

About your proposed solutions, it seems to me that the second proposed
solution would probadly be best since it eliminates the need to always
check for submit buttons on forms that use script.aculo.us. But maybe I
am just ignorant about your first proposed solution, how would one go
about implementing it?

Kind regards,

Mart-Mari

-----Original Message-----
From: Lukas Renggli [mailto:[hidden email]]
Sent: 14 Augustus 2006 07:48 nm
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: Re: RE: RE: [Seaside] Entire html stream in span after html
updater

Hi Mart-Mari,

> Please find a small example attached. In UpdaterTest1 you can select
> between Characters and Integers and when you add any of these two, it
> adds it to the list. In UpdaterTest2 (that inherits from UpdaterTest1)
I
> just added a submit button. When selecting characters or integers to
add
> to the list in the second version, the entire html content is
returned.

the problem with the attached code is that the JavaScript part of
script.aculo.us is triggering the button callback. This causes Seaside
to abort further callback processing and restart the rendering loop
with a full page render.

Now what can we do about this?

Choose one of these options:

- Instead of triggering the whole form you could just trigger the form
elements you require, in your case the changed select box.

- Change the JavaScript of script.aculo.us not to trigger submit
buttons.

- Change the way Seaside processes action-callbacks, this means to
ignore all action callbacks with script.aculo.us requests. This is
quite a deep change to Seaside, so maybe we should rethink that.

Cheers,
Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: RE: RE: RE: Entire html stream in span after html updater

Lukas Renggli
> About your proposed solutions, it seems to me that the second proposed
> solution would probadly be best since it eliminates the need to always
> check for submit buttons on forms that use script.aculo.us. But maybe I
> am just ignorant about your first proposed solution, how would one go
> about implementing it?

1. In this solution you would trigger the form-element instead of the
full form using #triggerFormElement:.

2. So far I tried to avoid changing the script.aculo.us code, since
this is an external library that I cannot control. Also it might be
surprising to find a different behavior than the one described in the
documentation on http://wiki.script.aculo.us. What would be probably
the best is to add a slightly different method to FormElement that
only serializes the input elements and that is internally used by
#triggerForm:

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside