• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

doubt in custom tag mock ques 17 HFSJ page:557

 
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Question 17 on Custom tags declare tags as non-empty and tagdepedent which means body of tag will be treated as text only, It can be script, EL or whatever but in Answer they say SimpleTag can't have scripting code inside body!!!. I am confused, Please clearify.

Thanks in advance.
 
Ranch Hand
Posts: 918
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

the custom tags can have like body content :
empty, scriptless, tagdepedent - the classic tags can have extra the JPS.
The custom tags can have an empty body, you can define the tag's body type with the "body-content" attribute from the tag directive (available only for the tag files).
Take a look on the JSP specification (on 1-177 for the jps_2_1).

Regards,
M
 
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I was just looking at that question in HFSJ, and I don't see anything about the tag body being tagdependent. If it really did specify tagdependent, then I think you'd be right that it could have whatever it wanted as the body.
 
Politics n. Poly "many" + ticks "blood sucking insects". Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic