Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

tag library doubt(Enthuware)

 
Poonam Agarwal
Ranch Hand
Posts: 324
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello ranchers,

please consider the following question from Enthuware mock..

You are given a tag library that has:

1. A tag named getMenu that takes an attribute 'subject' which can be a dynamic value.

2. A tag named getHeading that takes an attribute 'report'.

Which of the following are correct uses of this library?

1. <myTL:getMenu subject="Finance"/>

2. <myTL:getMenu subject="<myTL:getHeading report=1/>"/>

3. <myTL:getMenu subject='<myTL:getHeading report="1"/>'/>

4. <% String subject="HR";%> <myTL:getMenu subject="<%=subject%>"/>

5. <myTL:getHeading report="2"/>

Answer is 1, 4, 5.

From the given answers it seems that we are not allowed to embed one tag inside another tag's attribute list. (Although you can nest one tag inside another).???

Please correct me if I am wrong


Thanks
 
ankit kumar
Ranch Hand
Posts: 108
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As far as my knowledge is concern you can't pass a tag as a attribute of another tag.
But you can put one tag in the body of the another tag.
 
Poonam Agarwal
Ranch Hand
Posts: 324
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yeah!! me also believe same.. anybody else ??
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic