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 jstl  -  fmt Tag problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "jstl  -  fmt Tag problem" Watch "jstl  -  fmt Tag problem" New topic
Author

jstl - fmt Tag problem

Vijay Kumar
Ranch Hand

Joined: Jul 24, 2003
Posts: 260
hi..
I am facing problem in jstl. I have written a jsp file wich is using jstl,
<fmt> tag when I execute this file its gioves me an error







my jsp file is give blow

<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt" %>
<html>
<body>
<h1>Formatting with the default locale</h1>
<jsp:useBean id="now" class="java.util.Date" />
Date: <fmt:formatDate value="${now}" pattern="yyyy-MM-dd HH:mm"/>
Number: <fmt:formatNumber value="${now.time}" />
</body>
</html>


I am using apache-tomcat-5.5.12
please help me out.....
thanks
Balasubramani Dharmalingam
Ranch Hand

Joined: Dec 06, 2004
Posts: 116
Vijay
use jstl 1.1 instead of jstl 1.0 then it will work.


Balasubramani SD,<br />SCJP 1.4,SCWCD 1.4,SCJP 5.0<br /><a href="http://sd.balasubramani.googlepages.com" target="_blank" rel="nofollow">www.sd.balasubramani.googlepages.com</a>
Vijay Kumar
Ranch Hand

Joined: Jul 24, 2003
Posts: 260
hi...
Balasubramani thanks for it..
but I am already using jstl 1.1 (two jar files jstl.jar & statndard.jar)
I have used core tag like <c:set>,<c:forEach>,<c:choose> etc. they are runnig fine...
but with the <fmt> I am facing this problem..


regards
vijay
Balasubramani Dharmalingam
Ranch Hand

Joined: Dec 06, 2004
Posts: 116
Vijay
In jstl1.1 uri will be "http://java.sun.com/jsp/jstl/fmt"
But in your jsp it is
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt" %>
where u get jstl.jar and standard.jar ?
Vijay Kumar
Ranch Hand

Joined: Jul 24, 2003
Posts: 260
hi....
Balasubramani
thank you very much a lot actually in I was using wrong uri..
thanks for supporting me.....

vijay
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jstl - fmt Tag problem