The naming is based on NamingContainers.
* If this component is a descendant of a NamingContainer then the
* client id is of form "{namingContainerId}:{componentId}".
I can't remember all of which components implement NamingContainer,
but I think it's UIForm and UIData. UIData uses
"{namingContainerId}:{componentId_#}", I believe.
I think there's also a tomahawk extension attribute called "forceId",
which, when set to true, will bypass naming containers and use the raw
id value specified, but I haven't used it.
http://myfaces.apache.org/tomahawk/forceId.html
On 12/12/05, Steve Ivy <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I'm working on the front end for a JSF app, and I'm trying to add some
> interactivitiy to the interface via javascript. Typically you do a lot
> of:
>
> document.getElementById ('someId').etc ()
>
> But I find that setting the id in JSF usually results in something
> like id="content:_id35:nameHelp". I'm not sure how these ids are
> assigned, and I'm not sure how I can predict what id an element will
> have in order to acess it via javascript (or css for that matter, but
> that's another rant). Are there accepted methods of getting around
> this?
>
> Thanks,
>
> --Steve
>
> --
> Steve Ivy
> http://redmonk.net
>