This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes tagdependent body content Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "tagdependent body content" Watch "tagdependent body content" New topic
Author

tagdependent body content

Veena Pointi
Ranch Hand

Joined: Jun 20, 2002
Posts: 442
customTagTestBean.jsp



Request uri is http://localhost/ch9/customTagTestBean.jsp?userName=Krishna

Question 1
Given Body content tagdependent in tld,in the above code it was suppose to print ${userName},isn't it ?Because for body content tagdependent in HFSJ it says "The tag body is treated as plain text,so the EL is NOT evaluated and tags/actions are not triggered".But EL is getting evaluated .It displays Hello Krishna.


Question 2
Given Body content value "JSP",it throws following error
The TLD for the class foo.AdvisorTagHandler specifies an invalid body-content (JSP) for a SimpleTag.

Can anybody please clarify above questions?

Thanks
Veena


SCJP1.4
"Continuous effort - not strength or intelligence - is the key to unlocking our potential."
*Winston Churchill
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

The answer to Question 2 is explained in this FAQ.


[My Blog]
All roads lead to JavaRanch
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

About question 1, you'll have to show us your tag class, and your tld as well.
 
Don't get me started about those stupid light bulbs.
 
subject: tagdependent body content
 
Similar Threads
Question on Empty body content of Simple Tag Handlers
body-content as scriptless
org.apache.jasper.JasperException: Unable to compile class for JSP:
Clarification on EL syntax
how to use global variable in JSP (scriptless)