You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Paul Stanton <pa...@gunnsoft.com.au> on 2008/02/20 00:55:50 UTC

updateComponent from JavaScript

Hi all,

Is there something in the dojo library that i can call (in javascript) 
to request a component to update? I need to trigger this on a tapestry 
component, but the code must be called from the client side, ie not in java.

Suggestions?

Thanks, P.



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: updateComponent from JavaScript

Posted by Paul Stanton <pa...@gunnsoft.com.au>.
Andreas, thanks, calling updateComponent on a wrapping div works.

by the way, i was updating the whole table before, that wasn't working.
<table jwcid="tableView@contrib:TableView"...>

p.

Paul Stanton wrote:
> Oh, ok, i'll try and update a div surrounding the table, otherwise 
> back to JS i guess.
> Thanks.
>
> Andreas Andreou wrote:
>> yea, I know noticed you're trying to update parts of a table...
>>
>> IE6 (not sure about IE7) has trouble updating parts of tables...
>> There's a js trick to make this possible but it must be the first 
>> time i see
>> someone needing this in Tapestry... perhaps most people either update 
>> the whole
>> table, or just a div within a cell...
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: updateComponent from JavaScript

Posted by Paul Stanton <pa...@gunnsoft.com.au>.
Oh, ok, i'll try and update a div surrounding the table, otherwise back 
to JS i guess.
Thanks.

Andreas Andreou wrote:
> yea, I know noticed you're trying to update parts of a table...
>
> IE6 (not sure about IE7) has trouble updating parts of tables...
> There's a js trick to make this possible but it must be the first time i see
> someone needing this in Tapestry... perhaps most people either update the whole
> table, or just a div within a cell...
>
> On Thu, Feb 28, 2008 at 1:02 AM, Paul Stanton
> <pa...@gunnsoft.com.au> wrote:
>   
>> gah .. have to go back to plain old JS.
>>
>>
>>
>>  Paul Stanton wrote:
>>  > Thanks Andreas, that works great on Firefox, not sure why but not
>>  > working with ie. The listener method is being called, but the
>>  > component (contrib:TableView) is not its self does not change as it
>>  > should.
>>  >
>>  > Your ClientLink is working perfectly though, I've tried the same thing
>>  > using a button and an @EventListener and that doesn't work either.
>>  >
>>  > Andreas Andreou wrote:
>>  >> Hi -
>>  >> the 'traditional' way (without digging into internals) was to have an
>>  >> invisible DirectLink and trigger that with js.
>>  >>
>>  >> Recently, Igor added ClientLink to tacos latest snapshot
>>  >> (
>>  >> http://tacos.sourceforge.net/tacos4.1/tacos-core/tapdocs/net.sf.tacos.Tacos/ClientLink/index.html
>>  >>
>>  >> ) which adds a js function (named anyway you declare) that does the
>>  >> ajax call - you then just call it whenever you like...
>>  >>
>>  >>
>>  >>
>>  >> On 2/20/08, Paul Stanton <pa...@gunnsoft.com.au> wrote:
>>  >>
>>  >>> Hi all,
>>  >>>
>>  >>> Is there something in the dojo library that i can call (in javascript)
>>  >>> to request a component to update? I need to trigger this on a tapestry
>>  >>> component, but the code must be called from the client side, ie not
>>  >>> in java.
>>  >>>
>>  >>> Suggestions?
>>  >>>
>>  >>> Thanks, P.
>>  >>>
>>  >>>
>>  >>>
>>  >>> ---------------------------------------------------------------------
>>  >>> 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: updateComponent from JavaScript

Posted by Andreas Andreou <an...@gmail.com>.
yea, I know noticed you're trying to update parts of a table...

IE6 (not sure about IE7) has trouble updating parts of tables...
There's a js trick to make this possible but it must be the first time i see
someone needing this in Tapestry... perhaps most people either update the whole
table, or just a div within a cell...

On Thu, Feb 28, 2008 at 1:02 AM, Paul Stanton
<pa...@gunnsoft.com.au> wrote:
> gah .. have to go back to plain old JS.
>
>
>
>  Paul Stanton wrote:
>  > Thanks Andreas, that works great on Firefox, not sure why but not
>  > working with ie. The listener method is being called, but the
>  > component (contrib:TableView) is not its self does not change as it
>  > should.
>  >
>  > Your ClientLink is working perfectly though, I've tried the same thing
>  > using a button and an @EventListener and that doesn't work either.
>  >
>  > Andreas Andreou wrote:
>  >> Hi -
>  >> the 'traditional' way (without digging into internals) was to have an
>  >> invisible DirectLink and trigger that with js.
>  >>
>  >> Recently, Igor added ClientLink to tacos latest snapshot
>  >> (
>  >> http://tacos.sourceforge.net/tacos4.1/tacos-core/tapdocs/net.sf.tacos.Tacos/ClientLink/index.html
>  >>
>  >> ) which adds a js function (named anyway you declare) that does the
>  >> ajax call - you then just call it whenever you like...
>  >>
>  >>
>  >>
>  >> On 2/20/08, Paul Stanton <pa...@gunnsoft.com.au> wrote:
>  >>
>  >>> Hi all,
>  >>>
>  >>> Is there something in the dojo library that i can call (in javascript)
>  >>> to request a component to update? I need to trigger this on a tapestry
>  >>> component, but the code must be called from the client side, ie not
>  >>> in java.
>  >>>
>  >>> Suggestions?
>  >>>
>  >>> Thanks, P.
>  >>>
>  >>>
>  >>>
>  >>> ---------------------------------------------------------------------
>  >>> 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
>  >
>  >
>  >
>  >
>
>  --
>  Paul Stanton
>  Gunn Software Pty Ltd
>  Level 1, 24 Avalon Parade, Avalon, NSW 2107 Australia
>  Office: +61 2 9918 3666 (ext 503) | Fax: +61 2 9918 7388
>  E-Mail: paul.stanton@gunnsoft.com.au
>  Web: www.gunnsoft.com.au
>
>
>
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>  For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Andreas Andreou - andyhot@apache.org - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: updateComponent from JavaScript

Posted by Paul Stanton <pa...@gunnsoft.com.au>.
gah .. have to go back to plain old JS.

Paul Stanton wrote:
> Thanks Andreas, that works great on Firefox, not sure why but not 
> working with ie. The listener method is being called, but the 
> component (contrib:TableView) is not its self does not change as it 
> should.
>
> Your ClientLink is working perfectly though, I've tried the same thing 
> using a button and an @EventListener and that doesn't work either.
>
> Andreas Andreou wrote:
>> Hi -
>> the 'traditional' way (without digging into internals) was to have an
>> invisible DirectLink and trigger that with js.
>>
>> Recently, Igor added ClientLink to tacos latest snapshot
>> ( 
>> http://tacos.sourceforge.net/tacos4.1/tacos-core/tapdocs/net.sf.tacos.Tacos/ClientLink/index.html 
>>
>> ) which adds a js function (named anyway you declare) that does the
>> ajax call - you then just call it whenever you like...
>>
>>
>>
>> On 2/20/08, Paul Stanton <pa...@gunnsoft.com.au> wrote:
>>  
>>> Hi all,
>>>
>>> Is there something in the dojo library that i can call (in javascript)
>>> to request a component to update? I need to trigger this on a tapestry
>>> component, but the code must be called from the client side, ie not 
>>> in java.
>>>
>>> Suggestions?
>>>
>>> Thanks, P.
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> 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
>
>
>
>

-- 
Paul Stanton
Gunn Software Pty Ltd
Level 1, 24 Avalon Parade, Avalon, NSW 2107 Australia
Office: +61 2 9918 3666 (ext 503) | Fax: +61 2 9918 7388
E-Mail: paul.stanton@gunnsoft.com.au
Web: www.gunnsoft.com.au



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: updateComponent from JavaScript

Posted by Paul Stanton <pa...@gunnsoft.com.au>.
Thanks Andreas, that works great on Firefox, not sure why but not 
working with ie. The listener method is being called, but the component 
(contrib:TableView) is not its self does not change as it should.

Your ClientLink is working perfectly though, I've tried the same thing 
using a button and an @EventListener and that doesn't work either.

Andreas Andreou wrote:
> Hi -
> the 'traditional' way (without digging into internals) was to have an
> invisible DirectLink and trigger that with js.
>
> Recently, Igor added ClientLink to tacos latest snapshot
> ( http://tacos.sourceforge.net/tacos4.1/tacos-core/tapdocs/net.sf.tacos.Tacos/ClientLink/index.html
> ) which adds a js function (named anyway you declare) that does the
> ajax call - you then just call it whenever you like...
>
>
>
> On 2/20/08, Paul Stanton <pa...@gunnsoft.com.au> wrote:
>   
>> Hi all,
>>
>> Is there something in the dojo library that i can call (in javascript)
>> to request a component to update? I need to trigger this on a tapestry
>> component, but the code must be called from the client side, ie not in java.
>>
>> Suggestions?
>>
>> Thanks, P.
>>
>>
>>
>> ---------------------------------------------------------------------
>> 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: updateComponent from JavaScript

Posted by Andreas Andreou <an...@gmail.com>.
Hi -
the 'traditional' way (without digging into internals) was to have an
invisible DirectLink and trigger that with js.

Recently, Igor added ClientLink to tacos latest snapshot
( http://tacos.sourceforge.net/tacos4.1/tacos-core/tapdocs/net.sf.tacos.Tacos/ClientLink/index.html
) which adds a js function (named anyway you declare) that does the
ajax call - you then just call it whenever you like...



On 2/20/08, Paul Stanton <pa...@gunnsoft.com.au> wrote:
> Hi all,
>
> Is there something in the dojo library that i can call (in javascript)
> to request a component to update? I need to trigger this on a tapestry
> component, but the code must be called from the client side, ie not in java.
>
> Suggestions?
>
> Thanks, P.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Andreas Andreou - andyhot@apache.org - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org