Part of the value of Tapestry is that it assigns ids.  The id of the
form will *likely* be the same as the component id of the Form. 
However, inside loops (or when using Tapestry to develop portals) the
id will vary from what you specify (to ensure uniqueness).  That's why
Tapestry has the JavaScript templates (the .script files) to create
JavaScript customized to the ids allocated by Tapestry for forms and
form fields.

On 9/9/05, Chris Norris (JIRA) <[email protected]> wrote:
> Cannot dynamically set the id for a Form
> ----------------------------------------
> 
>          Key: TAPESTRY-634
>          URL: http://issues.apache.org/jira/browse/TAPESTRY-634
>      Project: Tapestry
>         Type: Sub-task
>   Components: Framework
>     Reporter: Chris Norris
> 
> 
> This was initially addressed in case 626 
> http://issues.apache.org/jira/browse/TAPESTRY-626
> 
> Justin's (who is a coworker of mine) real goal in that case was to be able to 
> dynamically create an id for a form.  We use that id for javascript functions 
> and bug testing.  His issue was that the framework was generating an ID as 
> well and both were being written as attributes in the html.  Howard's 
> solution was to disallow informal id tags for Form components by making "id" 
> a reserved parameter.  I think what we were hoping for was for the framework 
> to not write a generated id if we specify one, so that the FormSupportImpl's 
> render method would look like:
> 
>         if(!_form.getBindingNames().contains("id"))
>         {
>                 _writer.attribute("id", formId);
>         }
> 
> 
> --
> This message is automatically generated by JIRA.
> -
> If you think it was sent incorrectly contact one of the administrators:
>    http://issues.apache.org/jira/secure/Administrators.jspa
> -
> For more information on JIRA, see:
>    http://www.atlassian.com/software/jira
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


-- 
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to