• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Html struts tags attribuits

 
Rami Hailat
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All of us know that using html struts tag like this
will be rendered in HTML like this What i want is to add some attribute in the HTML struts tags to be just copied to the corresponding rendered HTML tag. Is that possible ?


example to be
 
Dawn Charangat
Ranch Hand
Posts: 249
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, you cannot.

The custom tag is rendered based on the TLD file which holds its definition. Any attribute that you add which is not a part of the TLD for this tag [like the validate attribute you added in the example] will not be tolerated by struts, and an exception will be thrown at runtime.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Note that the same isn't true for some S2 tags, but the S1 tags haven't gotten dynamic attribute support as of yet.
 
Rami Hailat
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic