File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes tag library doubt Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "tag library doubt" Watch "tag library doubt" New topic
Author

tag library doubt

Jagadeesh Seemakurthi
Greenhorn

Joined: Apr 18, 2011
Posts: 3
I have used the following code in in one jsp
<%@taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html"%>
<%@taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
Do i need to do anything like adding tld files anywhere???
Dont mind if it is a dumb question.....
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8994
    
    9

From the JSP Specification:
If the URI is a URL or URN, then the TLD is located by consulting the mapping indicated in web.xml extended using the implicit maps in the packaged tag libraries. If URI is pathname, it is interpreted relative to the root of the web application and should resolve to a TLD file directly, or to a JAR file that has a TLD file at location META-INF/taglib.tld.


So the way you have it written, no.


[How To Ask Questions On JavaRanch]
Jagadeesh Seemakurthi
Greenhorn

Joined: Apr 18, 2011
Posts: 3
Thanks joe..
I have added struts.jar in lib folder of WEB-INF..
Still i am able to see the output..
It is showing the following output



javax.servlet.jsp.JspException: Cannot find ActionMappings or ActionFormBeans collection
at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:747)
at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:443)
at jsp_servlet.__index._jsp__tag0(__index.java:119)
at jsp_servlet.__index._jspService(__index.java:91)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3504)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2186)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2092)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1406)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)

please fix it
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8994
    
    9

We have an entry in our FAQ regarding that issue (#12)
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: tag library doubt