You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Geoff Callender <ge...@gmail.com> on 2009/09/11 01:38:01 UTC
Problem with ZoneUpdater example
I can't figure why this example of ZoneUpdater (in a component)
doesn't work when a field is cleared...
http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxcomponents1
whereas this example of ZoneUpdater works just fine...
http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxonevent
Anyone?
Cheers,
Geoff
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Problem with ZoneUpdater in a component
Posted by Josh Canfield <jo...@thedailytube.com>.
I took a quick look at the page and it looked like it was getting
trimmed. Entering "<space><space><space>something" would result in
"something"
I checked firebug and the response is:
{"content":"something"}
So I poked around a bit then just did a wide search for String.trim
usage. I found what looks like the culprit here in
PageRenderQueueImple.java at line 163:
String content = root.getChildMarkup().trim();
In the case of the full page usage, you always have something else
included in the result so the response is:
{"content":"Welcome Dumpty."}
Josh
On Fri, Sep 11, 2009 at 3:41 PM, Geoff Callender
<ge...@gmail.com> wrote:
> That's right. ZoneUpdater works fine in a page, but not in a component.
>
> Here is ZoneUpdater in a page, working fine even when the field becomes
> empty or spaces::
>
>
> http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxonevent
>
> Here is ZoneUpdater in a component, not working when the field becomes empty
> or spaces:
>
>
> http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxcomponents1
>
> Does anyone know why?
>
> Geoff
>
>
> On 11/09/2009, at 1:02 PM, Kalle Korhonen wrote:
>
>> Yes, but I guess Geoff was asking why the same keyup event works fine
>> on the page, including non-printing chars.
>>
>> Kalle
>>
>>
>> On Thu, Sep 10, 2009 at 6:17 PM, Thiago H. de Paula Figueiredo
>> <th...@gmail.com> wrote:
>>>
>>> Playing with them a little, it seems to me that the keyup event ignores
>>> non-printing chars. Try typing some spaces: nothing happens. Then type
>>> any
>>> letter: the AJAX update is triggered. Have you tried the change event?
>>>
>>> --
>>> Thiago H. de Paula Figueiredo
>>> Consultor, desenvolvedor e instrutor em Java
>>> http://www.arsmachina.com.br/thiago
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
--
--
TheDailyTube.com. Sign up and get the best new videos on the internet
delivered fresh to your inbox.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Problem with ZoneUpdater in a component
Posted by Geoff Callender <ge...@gmail.com>.
That's right. ZoneUpdater works fine in a page, but not in a component.
Here is ZoneUpdater in a page, working fine even when the field
becomes empty or spaces::
http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxonevent
Here is ZoneUpdater in a component, not working when the field becomes
empty or spaces:
http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/javascript/ajaxcomponents1
Does anyone know why?
Geoff
On 11/09/2009, at 1:02 PM, Kalle Korhonen wrote:
> Yes, but I guess Geoff was asking why the same keyup event works fine
> on the page, including non-printing chars.
>
> Kalle
>
>
> On Thu, Sep 10, 2009 at 6:17 PM, Thiago H. de Paula Figueiredo
> <th...@gmail.com> wrote:
>> Playing with them a little, it seems to me that the keyup event
>> ignores
>> non-printing chars. Try typing some spaces: nothing happens. Then
>> type any
>> letter: the AJAX update is triggered. Have you tried the change
>> event?
>>
>> --
>> Thiago H. de Paula Figueiredo
>> Consultor, desenvolvedor e instrutor em Java
>> http://www.arsmachina.com.br/thiago
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Problem with ZoneUpdater example
Posted by Kalle Korhonen <ka...@gmail.com>.
Yes, but I guess Geoff was asking why the same keyup event works fine
on the page, including non-printing chars.
Kalle
On Thu, Sep 10, 2009 at 6:17 PM, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> Playing with them a little, it seems to me that the keyup event ignores
> non-printing chars. Try typing some spaces: nothing happens. Then type any
> letter: the AJAX update is triggered. Have you tried the change event?
>
> --
> Thiago H. de Paula Figueiredo
> Consultor, desenvolvedor e instrutor em Java
> http://www.arsmachina.com.br/thiago
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Problem with ZoneUpdater example
Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Playing with them a little, it seems to me that the keyup event ignores
non-printing chars. Try typing some spaces: nothing happens. Then type any
letter: the AJAX update is triggered. Have you tried the change event?
--
Thiago H. de Paula Figueiredo
Consultor, desenvolvedor e instrutor em Java
http://www.arsmachina.com.br/thiago
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org