aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes EL not working in my jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "EL not working in my jsp" Watch "EL not working in my jsp" New topic
Author

EL not working in my jsp

Salil Vverma
Ranch Hand

Joined: Sep 06, 2009
Posts: 255

Hey all,

As per my undersatanding of EL, would give the same result as or


but in my jsp the EL one is not working while all the others are working fine. Kindly help me to identify how to get this EL working. is there any thing I am doing wrong? or do I need to add any jars to get the EL working.

The JSP code



Output



Regards
Salil Verma
Chinmaya Chowdary
Ranch Hand

Joined: Apr 21, 2008
Posts: 432
Hi Salil.
The reasons of ignoring EL may be:
1)If your web.xml has an entry <el-ignored>true</el-ignored>,
or
2) Version declaration problems of web.xml. See this.
Salil Vverma
Ranch Hand

Joined: Sep 06, 2009
Posts: 255

Hey Chinmaya,
My web.xml does not have the entry of <el-ignored>true</el-ignored> alternatively web-app tag in my web.xml was not defined as mentioned in your given faq. When I try to add the web-app entry I get the following error message. and it does not let the application deployed in glassfish..

Error message -
Multiple annotations found at this line:
- Attribute "xmlns:xsi" must be declared for element type "web-app".
- Attribute "version" must be declared for element type "web-app".
- Attribute "xmlns" must be declared for element type "web-app".
- Attribute "xsi:schemaLocation" must be declared for element type "web-app".

The web.xml with these annotation is as attached below. Kindly let us know what change should I do in my web.xml to get this issue resolved.



Chinmaya Chowdary
Ranch Hand

Joined: Apr 21, 2008
Posts: 432
Hi Salil.
<?xml version="1.0" encoding="ISO-8859-1"?>

Please remove above enry in web.xml and try.
Amru Jahagirdar
Ranch Hand

Joined: Sep 16, 2009
Posts: 39
Hi Salil,

I was also facing the same problem. What I did was I delcared isELEgnored="false" in my page deractive and it started working.
this is not a very good option though as I don't want to specify it for every JSP page.

Amruta
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

Also remove the DOCTYPE from web.xml. See the deployment descriptor declaration here

Amru Jahagirdar wrote:Hi Salil,
I was also facing the same problem. What I did was I delcared isELEgnored="false" in my page deractive and it started working.
this is not a very good option though as I don't want to specify it for every JSP page.
Amruta

Yes, that's not a good option.


[My Blog]
All roads lead to JavaRanch
Salil Vverma
Ranch Hand

Joined: Sep 06, 2009
Posts: 255

Hey Christophe,

Thanks for your help, the below web.xml worked fine for me and EL started working.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: EL not working in my jsp