You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Andrew Court <an...@gmail.com> on 2009/04/30 03:25:02 UTC

Access unique clientId in AjaxFormLoop iteration

Each new iteration of AjaxFormLoop generated by an addRowLink event appends a
unique identifier to the clientId of elements in the form of -120f481f67e

Is it possible to access this value directly in order to pass it as a
parameter in onclick events for example?

Something  like:

<input t:type="checkbox" t:value="rate.onMon" t:clientId="weekday_0"
onclick="javascript:doAllCheckboxToggle('${uniqueId}')"/>

such that after render we would have:

<input type="checkbox" id="weekday_0-120f481f67e"
onclick="javascript:doAllCheckboxToggle('-120f481f67e')"/>


Any pointers gratefully received.

Thanks,
Andrew
-- 
View this message in context: http://www.nabble.com/Access-unique-clientId-in-AjaxFormLoop-iteration-tp23304122p23304122.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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


Re: Access unique clientId in AjaxFormLoop iteration

Posted by Andrew Court <an...@gmail.com>.
Anybody? 

What I'm looking for is the equivalent of the "index" parameter of the loop
component. How can this be done with AjaxFormLoop?

Andrew




Andrew Court wrote:
> 
> Each new iteration of AjaxFormLoop generated by an addRowLink event
> appends a unique identifier to the clientId of elements in the form of
> -120f481f67e
> 
> Is it possible to access this value directly in order to pass it as a
> parameter in onclick events for example?
> 
> Something  like:
> 
> <input t:type="checkbox" t:value="rate.onMon" t:clientId="weekday_0"
> onclick="javascript:doAllCheckboxToggle('${uniqueId}')"/>
> 
> such that after render we would have:
> 
> <input type="checkbox" id="weekday_0-120f481f67e"
> onclick="javascript:doAllCheckboxToggle('-120f481f67e')"/>
> 
> 
> Any pointers gratefully received.
> 
> Thanks,
> Andrew
> 

-- 
View this message in context: http://www.nabble.com/Access-unique-clientId-in-AjaxFormLoop-iteration-tp23304122p23352218.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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