You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Angelo Chen <an...@gmail.com> on 2015/03/29 16:56:53 UTC

dynamic css id

Hi,

Say I have a html like this:

 < div id="myid"></div >

that id is fixed to 'myid', I'd like to be able to change it to something
else during run time, let's say getting the value from a page property,
possible? Thanks,

Angelo

Re: dynamic css id

Posted by Dimitris Zenios <di...@gmail.com>.
Hi

<div id="${myId}"></div>

Then create a method in your java class public String getMyId() and return
your id

Dimitris Zenios

On Sun, Mar 29, 2015 at 5:56 PM, Angelo Chen <an...@gmail.com>
wrote:

> Hi,
>
> Say I have a html like this:
>
>  < div id="myid"></div >
>
> that id is fixed to 'myid', I'd like to be able to change it to something
> else during run time, let's say getting the value from a page property,
> possible? Thanks,
>
> Angelo
>