| Author |
Scriptless JSP and config param
|
Armand Thierry Bessala
Greenhorn
Joined: Apr 07, 2006
Posts: 9
|
|
Hello all, I have some init parameters for my JSP file and I wanted to display them without using scriptlet. With scriptlet I wrote this: and it work fine. Whithout scriptlet ( with EL ): How can I retreive servlet init paramameter fom DD. There is no "config" implicit variable for JSP file. Witch implicit variable can I use ? How ? This is my DD: Thank you.
|
Regards,<br />Armand<br />SCJP1.4
|
 |
Ed Ward
Ranch Hand
Joined: Jan 30, 2006
Posts: 147
|
|
|
Not sure you could do this without a scripting element. The examples I've seen have overridden jspInit() and from there used getServletConfig().getInitParameter("name") and then set it in a scoped attribute.
|
 |
Krishna Latha Grandhi
Ranch Hand
Joined: Nov 08, 2005
Posts: 110
|
|
|
See this link http://faq.javaranch.com/view?InitParamsThruExpressionLanguage
|
 |
Christophe Verré
Sheriff
Joined: Nov 24, 2005
Posts: 14672
|
|
Hi Krishna, With almost 100 posts, you've never heard of the ranch's naming policy ? Could you please read it and change your name accordingly ? http://www.javaranch.com/name.jsp
|
[My Blog]
All roads lead to JavaRanch
|
 |
Armand Thierry Bessala
Greenhorn
Joined: Apr 07, 2006
Posts: 9
|
|
Hi Ed, Hi Krishna, Thank you for your replies. I also seen the example with overriding of jspInit...I tougth that there was another way .. With krishna link, I see now there is no way I can directlly access theses values with EL...
|
 |
 |
|
|
subject: Scriptless JSP and config param
|
|
|