Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!

vishnu priya

Greenhorn
+ Follow
since Nov 06, 2009
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by vishnu priya

Hi
I am using the servlet outputstream in my javaclass as shown below.
public class DbReportServlet extends HttpServlet
{
protected void doGet(HttpServletRequest request, HttpServletResponse
response) throws ServletException, IOException
{
Connection connection;
ServletOutputStream servletOutputStream =
response.getOutputStream();
InputStream reportStream =
getServletConfig().getServletContext().getResourceAsStream
("/reports/DbReport.jasper");
try
{
Class.forName("com.mysql.jdbc.Driver");
connection = DriverManager.getConnection ("jdbc:mysql://
localhost:3306/flightstats?user=dbuser&password=secret");
JasperRunManager.runReportToPdfStream(reportStream,
servletOutputStream, new HashMap(), connection);
connection.close();
response.setContentType("application/pdf");
servletOutputStream.flush();
servletOutputStream.close();
}
catch (Exception e)
{
// display stack trace in the browser
StringWriter stringWriter = new StringWriter();
PrintWriter printWriter = new PrintWriter(stringWriter);
e.printStackTrace(printWriter);
response.setContentType("text/plain");
response.getOutputStream().print(stringWriter.toString());
}
}
}

Now i need to redirect to another jsp and display the outputstream content in the jsp page.
I m stuck with this problem.
Please help me out....
Thanks in advance.
10 years ago
Hi
I am using jasperreports in my java application.And its working fine......
I am able to create reports and can export it to either pdf or any other format.
But i want to report to open at the same time.
i.e., When i click GenerateReport button in my jsp it should create a pdf report and open the pdf document in acrobat reader.
Report generation is fine but can any one please tell me how to open the report at that time.
I had used jasperrunmanager and jasperexportmanager.
But if i am usng jasperviewer.viewreport it was displaying the report in jasperassistant, in the same way i want to pdf to open.
Please help me out
Thanks in advance
Hi i have placed an object in session in my action class as
PortletRequest PR_RequestObj;
PR_RequestObj.getPortletSession().setAttribute("CUSTOBJ",cust_details,PortletSession.APPLICATION_SCOPE);

Now i want the object in my jsp.How can i access it
I had tried for
<%
Customer_details cust_details_obj = (Customer_details)portletRequest.getPortletSession().getAttribute("CUSTOBJ");
%>
but it was showing an error with portletrequest
Please help me with this

10 years ago
Hi...
I am having the same the problem.
I am getting the same exception as mentioned above.
Can any one please help me out.









Thanks in advance
Hi,
I want to create a report in my portal page.
I had tried of creating a pdf,html report from jrxml file and it was creating the reports in the specified location by jasperexportmanager.
Now i want those report details to be on portal page.

So where should i keep my jrxml file in the web project and what code should be written in jsp page and java class.

Thanks in advance
10 years ago
do you have any idea of pentaho reports..?
Hi
i am developing a portal application in weblogic .I want to include reports in that application
can you please tell me how to do it.what are the different types of reports?
which reports can i include in portal application?
what are the requirements are needed ?
can you please tell me the procedure ?
hi i am using struts2 select tag for a dropdown list
after selecting a particular element i need to display that selected value in another jsp

my select tag is
<s:select name="country" label="Country" headerKey="3" headerValue="---Select One---" list="country"/>

how can i get the selected value?
10 years ago
I am using struts 2.1.8 in weblogic portal and i am getting this error
my web.xml and portlet.xml are given below

The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.
javax.portlet.UnavailableException: The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.

at com.bea.portlet.container.PortletStub.createPortletInstance(PortletStub.java:744)

at com.bea.portlet.container.PortletStub.getPortletInstance(PortletStub.java:677)

at com.bea.portlet.container.PortletStub.init(PortletStub.java:215)

at com.bea.portlet.container.AppContainer.invokeRender(AppContainer.java:803)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.fireRender(JavaPortletContent.java:264)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.renderInternal(JavaPortletContent.java:159)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.beginRender(JavaPortletContent.java:106)

at com.bea.netuix.servlets.controls.application.laf.ContentControlRenderer.beginRender(ContentControlRenderer.java:48)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:352)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:326)

at com.bea.netuix.nf.UIControl.render(UIControl.java:582)

at com.bea.netuix.servlets.controls.PresentationContext.render(PresentationContext.java:486)

at com.bea.netuix.servlets.util.RenderToolkit.renderChild(RenderToolkit.java:146)

at com.bea.netuix.servlets.jsp.taglib.RenderChild.doStartTag(RenderChild.java:62)

at jsp_servlet._framework._skeletons._default.__flowlayout._jspService(__flowlayout.java:271)

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.onAddToMapException(ServletStubImpl.java:408)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:318)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)

at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:505)

at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:432)

at com.bea.netuix.servlets.controls.application.laf.JspTools.renderJsp(JspTools.java:130)

at com.bea.netuix.servlets.controls.application.laf.JspControlRenderer.beginRender(JspControlRenderer.java:72)

at com.bea.netuix.servlets.controls.application.laf.PresentationControlRenderer.beginRender(PresentationControlRenderer.java:65)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.runOutbound(Lifecycle.java:208)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:168)

at com.bea.netuix.servlets.manager.UIServlet.runLifecycle(UIServlet.java:388)

at com.bea.netuix.servlets.manager.UIServlet.processControlTree(UIServlet.java:301)

at com.bea.netuix.servlets.manager.PortalServlet.service(PortalServlet.java:927)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

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.TailFilter.doFilter(TailFilter.java:26)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.portal.tools.servlet.http.HttpContextFilter.doFilter(HttpContextFilter.java:60)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.p13n.servlets.PortalServletFilter.doFilter(PortalServletFilter.java:336)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3502)

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)


web.xml :-
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" 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">;
<display-name>StrutsSample</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>

<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<filter>
<filter-name>PageFlowJspFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowJspFilter</filter-class>
</filter>
<filter>
<filter-name>PageFlowForbiddenFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowForbiddenFilter</filter-class>
<init-param>
<param-name>response-code</param-name>
<param-value>404</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jsp</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jspx</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.java</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jsfb</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jpfs</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.PageFlowContextListener</listener-class>
</listener>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.HttpSessionMutexListener</listener-class>
</listener>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.PageFlowActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/_pageflow/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.xmlhttprequest.XmlHttpRequestServlet</servlet-class>
</servlet>


<servlet id="Struts2PortletDispatcherServlet">
<servlet-name>Struts2PortletDispatcherServlet</servlet-name>
<servlet-class>org.apache.struts2.portlet.dispatcher.DispatcherServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.jpf</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.xhr</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.render</url-pattern>
</servlet-mapping>

</web-app>


Portlet.xml :-

<?xml version="1.0" encoding="UTF-8"?>
<portlet-app version="1.0"
xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
id="my-portlet-app">

<portlet>
<description>Hello World </description>
<portlet-name>HelloWorld</portlet-name>
<display-name> hello world </display-name>
<portlet-class>org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher</portlet-class>
<init-param>
<!-- Portlet namespace -->
<name>portletNamespace</name>
<value>/portletA</value>
</init-param>
<init-param>
<!-- The base namespace of the view portlet mode -->
<name>viewNamespace</name>
<value>/view</value>
</init-param>
<init-param>
<!-- The default action to invoke in view mode -->
<name>defaultViewAction</name>
<value>index</value>
</init-param>

<supports>
<mime-type>text/html</mime-type>
<portlet-mode>view</portlet-mode>
</supports>
<portlet-info>
<title>HelloWorld</title>
</portlet-info>
</portlet>
</portlet-app>


Can any one please help me .............?
10 years ago
I am using struts 2.1.8 in weblogic portal and i am getting this error
my web.xml and portlet.xml are given below

The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.
javax.portlet.UnavailableException: The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.

at com.bea.portlet.container.PortletStub.createPortletInstance(PortletStub.java:744)

at com.bea.portlet.container.PortletStub.getPortletInstance(PortletStub.java:677)

at com.bea.portlet.container.PortletStub.init(PortletStub.java:215)

at com.bea.portlet.container.AppContainer.invokeRender(AppContainer.java:803)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.fireRender(JavaPortletContent.java:264)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.renderInternal(JavaPortletContent.java:159)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.beginRender(JavaPortletContent.java:106)

at com.bea.netuix.servlets.controls.application.laf.ContentControlRenderer.beginRender(ContentControlRenderer.java:48)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:352)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:326)

at com.bea.netuix.nf.UIControl.render(UIControl.java:582)

at com.bea.netuix.servlets.controls.PresentationContext.render(PresentationContext.java:486)

at com.bea.netuix.servlets.util.RenderToolkit.renderChild(RenderToolkit.java:146)

at com.bea.netuix.servlets.jsp.taglib.RenderChild.doStartTag(RenderChild.java:62)

at jsp_servlet._framework._skeletons._default.__flowlayout._jspService(__flowlayout.java:271)

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.onAddToMapException(ServletStubImpl.java:408)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:318)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)

at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:505)

at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:432)

at com.bea.netuix.servlets.controls.application.laf.JspTools.renderJsp(JspTools.java:130)

at com.bea.netuix.servlets.controls.application.laf.JspControlRenderer.beginRender(JspControlRenderer.java:72)

at com.bea.netuix.servlets.controls.application.laf.PresentationControlRenderer.beginRender(PresentationControlRenderer.java:65)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.runOutbound(Lifecycle.java:208)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:168)

at com.bea.netuix.servlets.manager.UIServlet.runLifecycle(UIServlet.java:388)

at com.bea.netuix.servlets.manager.UIServlet.processControlTree(UIServlet.java:301)

at com.bea.netuix.servlets.manager.PortalServlet.service(PortalServlet.java:927)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

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.TailFilter.doFilter(TailFilter.java:26)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.portal.tools.servlet.http.HttpContextFilter.doFilter(HttpContextFilter.java:60)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.p13n.servlets.PortalServletFilter.doFilter(PortalServletFilter.java:336)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3502)

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)


web.xml :-
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" 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">;
<display-name>StrutsSample</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>

<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<filter>
<filter-name>PageFlowJspFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowJspFilter</filter-class>
</filter>
<filter>
<filter-name>PageFlowForbiddenFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowForbiddenFilter</filter-class>
<init-param>
<param-name>response-code</param-name>
<param-value>404</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jsp</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jspx</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.java</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jsfb</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jpfs</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.PageFlowContextListener</listener-class>
</listener>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.HttpSessionMutexListener</listener-class>
</listener>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.PageFlowActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/_pageflow/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.xmlhttprequest.XmlHttpRequestServlet</servlet-class>
</servlet>


<servlet id="Struts2PortletDispatcherServlet">
<servlet-name>Struts2PortletDispatcherServlet</servlet-name>
<servlet-class>org.apache.struts2.portlet.dispatcher.DispatcherServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.jpf</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.xhr</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.render</url-pattern>
</servlet-mapping>

</web-app>


Portlet.xml :-

<?xml version="1.0" encoding="UTF-8"?>
<portlet-app version="1.0"
xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd";
id="my-portlet-app">

<portlet>
<description>Hello World </description>
<portlet-name>HelloWorld</portlet-name>
<display-name> hello world </display-name>
<portlet-class>org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher</portlet-class>
<init-param>
<!-- Portlet namespace -->
<name>portletNamespace</name>
<value>/portletA</value>
</init-param>
<init-param>
<!-- The base namespace of the view portlet mode -->
<name>viewNamespace</name>
<value>/view</value>
</init-param>
<init-param>
<!-- The default action to invoke in view mode -->
<name>defaultViewAction</name>
<value>index</value>
</init-param>

<supports>
<mime-type>text/html</mime-type>
<portlet-mode>view</portlet-mode>
</supports>
<portlet-info>
<title>HelloWorld</title>
</portlet-info>
</portlet>
</portlet-app>


Can anyone please tell me what should i do...?
10 years ago
in my jsp i am getting an error as "cannot find the tag library descriptor for "/struts-tag" "
When i am using struts2-core-2.1.6 jar i am not getting this error but when using struts2-core-2.1.8 i am getting the above error
I want to use the latest version
Is there any problem with 2.1.8 jar
What changes shall i make for the program to execute
10 years ago
i am using struts 2.1.6 and i am getting the following error
When i searched for that some had said for a change in log 4j
but i am not using any log4j in my application


INFO: Deploying erb application archive Sample4.ear
NOV 9, 2009 11:54:01 AM com.opensymphony.xwork2.util.logging.jdk.JDKLogger info
INFO: Parsing configuration file [struts-default.xml]
NOV 9, 2009 11:54:01 AM org.apache.catalina.core.StandardContext Start
SERVERE: Error filterStart
NOV 9, 2009 11:54:01 AM org.apache.catalina.core.StandardContext Start
SERVERE: Context [/Sample4]startup failed due to previous errors


What is log4j ....and what can i do
10 years ago
Hi
while i was copying the struts.xml in src its not pasting in eclipse
but in my war i have it in web-inf\classes folder
but still i am getting the same error

INFO: Starting service Catalina
Nov 6, 2009 11:46:32 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying erb application archive Sample4.ear
NOV 6, 2009 11:46:33 PM com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
INFO: Parsing configuration file [struts-default.xml]
NOV 6, 2009 11:46:34 PM org.apache.catalina.core.StandardContext Start
SERVERE: Error filterStart
NOV 6, 2009 11:46:35 PM org.apache.catalina.core.StandardContext Start
SERVERE: Context [/Sample4]startup failed due to previous errors

I am using servlet 2.4,tomcat 6.0.16, struts 2.1.8 jars
What can i do and will you please send me the list of jars used for a struts 2 application?
10 years ago