Glad I'm not going crazy!
https://issues.apache.org/jira/browse/TAP5-764
I've come up with a hack to get the element by name using
document.getElementsByName().
Norman Franke
Answering Service for Directors, Inc.
www.myasd.com
On Jul 6, 2009, at 4:18 PM, Robert Zeigler wrote:
Awesome. Not only does hidden not support ClientElement, it also
doesn't support informal parameters (thus explaining why id didn't
pass through!).
Please add a ticket to improve the Hidden component in those ways.
As far as the "bug", the behavior of only rendering the client id if
getClientId is called for ClientElement's is documented (if I had a
minute, I could find where :). This was a case of trade-off: most
elements don't actually need an id on them, even though tapestry
will assign them one, and that can have a decent impact on markup
size (especially if you're using anonymous components! eg,
id="textfield", id="textfield-0" and so forth). So the way (most)
tapestry components distinguish between needing an id or not is
whether "getClientId" was called.
Cheers,
Robert
On Jul 6, 2009, at 7/62:03 PM , Norman Franke wrote:
Alas, one can't add a mixin to a t:hidden field. It claims that my
hidden field is not assignable to ClientElement.
Norman Franke
Answering Service for Directors, Inc.
www.myasd.com
On Jul 6, 2009, at 2:16 PM, Robert Zeigler wrote:
id isn't rendered because nowhere in the server-side code is
"getClientId" called.
Check out:
https://issues.apache.org/jira/browse/TAP5-680
Which describes this. There's a new mixin in the 5.2-SNAPSHOT
branch (RenderClientId) that ensures the client id is rendered for
a form element.
It's a small mixin that you can easily add yourself, if you want;
otherwise, just be sure to call "getClientId" on the component
instance from the server.
Robert
On Jul 6, 2009, at 7/61:02 PM , Norman Franke wrote:
I'm trying to use a Hidden component to allow my web page to
automatically submit a login page if a browser-injected
JavaScript object exists. (Allowing my web app to auto-login if
run in my embedded web browser.)
I've created the field thusly:
<input t:type="Hidden" t:id="login_id" value="${loginId}"/>
However, it doesn't really work. The control never gets an "id"
so Prototype can't find it to set the value.
First, why doesn't it get an ID (the submit button does) and is
there a better way of doing this?
Norman Franke
Answering Service for Directors, Inc.
www.myasd.com
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org