File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes Expression Language in Taglibs Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Expression Language in Taglibs" Watch "Expression Language in Taglibs" New topic
Author

Expression Language in Taglibs

vidya archana
Ranch Hand

Joined: Oct 29, 2002
Posts: 36
hi,
I am trying to develop a jsp page using taglibs. In the code i am assigning values to the tag attributes using Expression Langage. But the El just shows up as simple text in the HTML.. not getting the value of the EL. y?
In the tutorial for EL, it is said that, it is possible to control the evaluation of the EL expressions by specifying isELEnabled value in the page directive. Also it is said that the default value of isELEnabled is "true" which means without specifying anything in the page directive, the container will evaluate the EL expressions and will return the result.
In my code, its not working
pls help
Chetan M
Ranch Hand

Joined: Dec 18, 2002
Posts: 43
Hi Vidya,
When you say taglib attributes not taking expression value, first that comes to mind is tld file rtexprvalue tag value.
Your .tld file should contain
<rtexprvalue>false</rtexprvalue>
For example, say your taglib attribute is content,
then for the same, entry in your tld file should be
...
<attribute>
<name>content</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue></attribute>
...
Please change your .tld file and see it works or not.
Its better to have rtexprvalue tag value always set to true.
Hope this helps.
[ May 06, 2003: Message edited by: Chetan M ]

No matter how much you know today, you will have to know more tomorrow.<br /> Hakunamatata !!!
vidya archana
Ranch Hand

Joined: Oct 29, 2002
Posts: 36
hi,
yes.I have specified the <rtexprvalue> in my code.
this is the portion of tld file ..
/*********/
<attribute>
<name>name</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
/*********/
still the thing doesn't work ..
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Expression Language in Taglibs