Login

mvnForum

mvnForum Homepage Welcome Guest
  Search  
  Index  | Recent Threads  | Unanswered Threads  | List Polls  | Public Albums  | Who's Online  | Help


Quick Go »


No member browsing this thread
Thread Status: Active
Total posts in this thread: 3
Post new Thread
Author
Previous Thread This topic has been viewed 679 times and has 2 replies Next Thread
Female MrMaxx
Stranger




Joined: Sep 1, 2008
Post Count: 1
Status: Offline
Reply to this Post  Reply with Quote 
JSTL 1.0 <-> 1.1

There is something i don't understand:

I downloaded the src version of mvnForum and installed and configured it on a tomcat 5.5.26. It works fine, when running in its own context.

BUT I want to integrate it within my application, sharing the same context, so i changed the web.xml. Im currently able to open the link to the forum, but i get a 500 on:


13:57:47,216 ERROR [CustomExceptionHandler] org.apache.jasper.JasperException: /mvnplugin/mvnforum/user/inc_common.jsp(90,0) According to TLD or attribute directive in tag file, attribute value does not accept any expressions
org.apache.jasper.JasperException: /mvnplugin/mvnforum/user/inc_common.jsp(90,0) According to TLD or attribute directive in tag file, attribute value does not accept any expressions


In my deployed version im not using the standard.jar and jstl.jar from mvnforum, but my own, which is
Specification-Title: JavaServer Pages Standard Tag Library (JSTL)

Specification-Version: 1.1

Implementation-Title: jakarta-taglibs 'standard': an implementation of

JSTL

Implementation-Version: 1.1.2


Thats where my problem begins:
I dont know why the standalone Version works, because in fmt.tld for jstl v.1.0 it says for tag setLocale:
<attribute>
<name>value</name>
<required>true</required>
<rtexprvalue>false</rtexprvalue>
</attribute>

This is the Version you are using, which is also in your standard.jar.

In /mvnplugin/mvnforum/user/inc_common.jsp the tag is used as followed:
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt" %>
<fmt:setLocale value="${currentLocale}" scope="page"/>

http://java.sun.com/jstl/fmt is the URI for jstl v1.0 ... http://java.sun.com/jsp/jstl/fmt is for 1.1.
So when i use my Version the statement above fails, because the use of EL in that value attribute, because of the above reasons.

But why is it working in the standalon Version, where only jstl 1.0 is available?

I can fix this problem by adding the correct URI, but then the mvntaglib faults saying the same (this time its the html tags locale attribute which forbids dynamic expressions).

Any Solution, bow i can force jstl 1.1 on mvnForum?

Best regards,
Maximilian Höflich
[Sep 2, 2008 12:14:06 PM] Show Printable Version of Post    View Member Profile    Send Private Message    Hidden to Guest [Link] Report threatening or abusive post: please login first  Go to top 
Female synchroseb
Stranger




Joined: Sep 15, 2008
Post Count: 1
Status: Offline
Reply to this Post  Reply with Quote 
Re: JSTL 1.0 <-> 1.1

I have the same problem. Any solution?
[Sep 15, 2008 2:30:21 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Female xuanthai
Stranger




Joined: Oct 22, 2008
Post Count: 1
Status: Offline
Reply to this Post  Reply with Quote 
biggrin Re: JSTL 1.0 <-> 1.1

The Solution

step 1: Check web.xml change to

<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">

step 2: Deactivate the EL in the Deployment Descriptor :


<jsp-config>
<jsp-property-group>
<display-name>Ignore EL</display-name>
<url-pattern>*.jsp</url-pattern>
<el-ignored>true</el-ignored>
</jsp-property-group>
</jsp-config>

--------------------Display Result -------------
<?xml version="1.0" encoding="UTF-8"?>

<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">
..................
...................
<jsp-config>
<jsp-property-group>
<display-name>Ignore EL</display-name>
<url-pattern>*.jsp</url-pattern>
<el-ignored>true</el-ignored>
</jsp-property-group>
</jsp-config>
</web-app>

good lucky!
[Oct 22, 2008 7:45:11 AM] Show Printable Version of Post    View Member Profile    Send Private Message    Hidden to Guest [Link] Report threatening or abusive post: please login first  Go to top 
Show Printable Version of Thread  Post new Thread