Struts in Taglib

hi,
In the taglib struts tag code is used in ou.print("<bean:message key='text.Name'/>")
The value for bean.Message is not displayed when the jsp is shown..
Can you please tell me how to show the value, while using taglibs..
sj

Hi,
this is the piece of code written in taglib
JspWriter out = pageContext.getOut();
Iterator itr = clnResponse.iterator();      
while(itr.hasNext()){
objResp = (ResTO)itr.next();
out.print("<tr>");
out.print("<td width='5%' height='16' align='left'><font face='Arial' size='2'> <bean:message key="ABC.SelectClient"/></font></td>");
iterating over the object and displaying all the rows...
bean:message has the column name, I verified and resources has the key.
if this bean:message is taken out from the taglib and kept in jsp. it works...
where as in taglib, it dosen't..
kindly help me in fixing it
thanks in advance.
SJ

Similar Messages

  • Re: Warning about taglib in NitroX for Struts 2.0

    This is because NitroX 2.0 is smarter about JSP 2.0 and servlet 2.4.
    In the web.xml version 2.4 the taglib tags should be nested inside a
    <jsp-config> tag. Actually, the next NitroX build will report an error about
    this.
    M7 Support
    "Paul K. Courtney" <[email protected]> wrote in message
    news:[email protected]...
    I just installed 2.0 on my machine and I'm getting a new warning about mytaglibs that was not present in 1.0 or 1.1.
    At the top of my JSP I have
    %@ taglib uri="/tags/struts-logic" prefix="logic" %
    My web.xml is as follows:
    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    web-app version="2.4"
    servlet
    servlet-name>action</servlet-name
    servlet-class>org.apache.struts.action.ActionServlet</servlet-class
    init-param
    param-name>application</param-name
    param-value>resources.application</param-value
    /init-param
    init-param
    param-name>config</param-name
    param-value>/WEB-INF/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>log4j-init</servlet-name
    servlet-class>app.utility.Log4jInit</servlet-class
    init-param
    param-name>log4j-init-file</param-name
    param-value>WEB-INF/classes/log4j.lcf</param-value
    /init-param
    load-on-startup>1</load-on-startup
    /servlet
    servlet-mapping
    servlet-name>action</servlet-name
    url-pattern>*.do</url-pattern
    /servlet-mapping
    servlet-mapping
    url-pattern>/SurveyGenerator</url-pattern><servlet-name>SurveyGenerator</se
    rvlet-name>
    /servlet-mappingservlet-mapping
    url-pattern>/CatchParam</url-pattern><servlet-name>CatchParam</servlet-name
    /servlet-mapping
    servlet-mapping
    url-pattern>/htmlVers</url-pattern><servlet-name>IQRunSurvey</servlet-name
    /servlet-mapping
    servlet-mapping
    url-pattern>/FinishPage</url-pattern><servlet-name>FinishPage</servlet-name
    /servlet-mapping
    servlet-mapping
    url-pattern>/LastPage</url-pattern><servlet-name>LastPage</servlet-name
    /servlet-mapping
    welcome-file-list
    welcome-file
    index.jsp
    /welcome-file
    /welcome-file-list
    taglib
    taglib-uri>/tags/struts-bean</taglib-uri
    taglib-location>/WEB-INF/struts-bean.tld</taglib-location
    /taglib
    taglib
    taglib-uri>/tags/struts-html</taglib-uri
    taglib-location>/WEB-INF/struts-html.tld</taglib-location
    /taglib
    taglib
    taglib-uri>/tags/struts-logic</taglib-uri
    taglib-location>/WEB-INF/struts-logic.tld</taglib-location
    /taglib
    taglib
    taglib-uri>/app</taglib-uri
    taglib-location>/WEB-INF/app.tld</taglib-location
    /taglib
    /web-app
    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    +++++++++++++
    >
    So, why am I getting the warning?
    Paul

    Hello
    According users manuals document for Portege M100 two optical disc drivers are compatible with your Portege M100L:
    TOSHIBA SD-C2612
    TEAC DW-224E
    So if you want to have good working drive obtain one of them.

  • Tag handler class was not found "org.apache.struts.taglib.tiles.InsertTag"

    Hi All,
    I have a proble deploying my app with struts 1.3.10, when I run under tomcat 6 on my eclipse, it´s fine, but when I deploy on weblogic send next exception:
    ####<Apr 2, 2013 4:24:19 PM CDT> <Info> <ServletContext-/slagentes> <DSWLC01K> <svr-slisto> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1364937859494> <BEA-000000> <layout.jsp:142:14: The tag handler class was not found "org.apache.struts.taglib.tiles.InsertTag".
    <tiles:insert attribute="content"/>
    ^----------^
    layout.jsp:142:14: The tag handler class was not found "org.apache.struts.taglib.tiles.InsertTag".
    <tiles:insert attribute="content"/>
    ^----------^
    >
    ####<Apr 2, 2013 4:24:19 PM CDT> <Error> <HTTP> <DSWLC01K> <svr-slisto> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1364937859499> <BEA-101017> <[ServletContext@159254910[app:slagentes module:/slagentes path:null spec-version:3.0], request: weblogic.servlet.internal.ServletRequestImpl@5ebf5ebf[
    POST /slagentes/login.do HTTP/1.1
    Connection: keep-alive
    Content-Length: 37
    Cache-Control: max-age=0
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    Origin: http://172.17.12.129:7004
    User-Agent: Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.43 Safari/537.31
    Content-Type: application/x-www-form-urlencoded
    Referer: http://172.17.12.129:7004/slagentes/
    Accept-Encoding: gzip,deflate,sdch
    Accept-Language: es-ES,es;q=0.8
    Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
    ]] Root cause of ServletException.
    weblogic.servlet.jsp.CompilationException: Failed to compile JSP /jsp/template/layout.jsp
    layout.jsp:142:14: The tag handler class was not found "org.apache.struts.taglib.tiles.InsertTag".
    <tiles:insert attribute="content"/>
    ^----------^
    layout.jsp:142:14: The tag handler class was not found "org.apache.struts.taglib.tiles.InsertTag".
    <tiles:insert attribute="content"/>
    ^----------^
    at weblogic.servlet.jsp.JavelinxJSPStub.reportCompilationErrorIfNeccessary(JavelinxJSPStub.java:225)
    at weblogic.servlet.jsp.JavelinxJSPStub.compilePage(JavelinxJSPStub.java:161)
    at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:237)
    at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:190)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:281)
    at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:453)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:364)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)
    at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:567)
    at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:263)
    at org.apache.struts.tiles.commands.TilesPreProcessor.doForward(TilesPreProcessor.java:260)
    at org.apache.struts.tiles.commands.TilesPreProcessor.execute(TilesPreProcessor.java:217)
    at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:191)
    at org.apache.commons.chain.generic.LookupCommand.execute(LookupCommand.java:305)
    at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:191)
    at org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequestProcessor.java:283)
    at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)
    at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:462)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:751)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:844)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:242)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:216)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:132)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:338)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3284)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3254)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
    at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:57)
    at weblogic.servlet.internal.WebAppServletContext.doSecuredExecute(WebAppServletContext.java:2163)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2089)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2074)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1513)
    at weblogic.servlet.provider.ContainerSupportProviderImpl$WlsRequestExecutor.run(ContainerSupportProviderImpl.java:254)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
    >
    My weblogic.xml is
    <?xml version="1.0" encoding="UTF-8"?>
    <wls:weblogic-web-app
         xmlns:wls="http://xmlns.oracle.com/weblogic/weblogic-web-app"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd http://xmlns.oracle.com/weblogic/weblogic-web-app http://xmlns.oracle.com/weblogic/weblogic-web-app/1.4/weblogic-web-app.xsd">
         <wls:container-descriptor>
              <wls:prefer-web-inf-classes>true</wls:prefer-web-inf-classes>
         </wls:container-descriptor>     
    </wls:weblogic-web-app>     
    and my weblogic-application.xml is
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <weblogic-application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://www.bea.com/ns/weblogic/weblogic-application http://www.bea.com/ns/weblogic/weblogic-application/1.0/weblogic-application.xsd"
         xmlns="http://www.bea.com/ns/weblogic/weblogic-application">
         <application-param>
              <param-name>webapp.encoding.default</param-name>
              <param-value>UTF-8</param-value>
         </application-param>
         <prefer-application-packages>
              <package-name>antlr.*</package-name>          
              <package-name>org.apache.*</package-name>          
              <package-name>javax.xml.rpc.*</package-name>
              <package-name>javax.xml.namespace.*</package-name>
              <package-name>javax.xml.messaging.*</package-name>
              <package-name>javax.xml.soap.*</package-name>
              <package-name>javax.servlet.jsp.jstl.*</package-name>
         </prefer-application-packages>
    </weblogic-application>
    please help me

    The struts-template tld has been deprecated in favour of the tiles taglib.
    If you are using anything above struts 1.0, then you should be using tiles.
    Most probably the support files for the struts-template taglib are not in your distribution.
    Cheers,
    evnafets

  • How to  configure  for struts-config.xml

    Hi
    I am having a JSp which is Mapped to anothr action through the registration.The registartion is mapped to action
    <%@ page contentType="text/html;charset=UTF-8" %>
    <%@ page import="org.apache.struts.validator.ValidatorPlugIn" session="true" %>
    <%@ page import="org.apache.struts.Globals" %>
    <%@ taglib uri="/tags/struts-bean" prefix="bean" %>
    <%@ taglib uri="/tags/struts-html" prefix="html" %>
    <%@ taglib uri="/tags/struts-logic" prefix="logic" %>
    <html:html locale="true">
    <head>
    <title><bean:message key="index.title"/></title>
    <html:base/>
    </head>
    <body bgcolor="white">
    <logic:notPresent name="<%= Globals.MESSAGES_KEY %>" >
      <font color="red">
        ERROR:  Application resources not loaded -- check servlet container
        logs for error messages.
      </font>
    </logic:notPresent>
    <%-- :TODO: Need code to do this with moudles
    <logic:notPresent name="<%= ValidatorPlugIn.VALIDATOR_KEY %>" >
      <font color="red">
        ERROR:  Validator resources not loaded -- check Commons Logging
        logs for error messages.
      </font>
    </logic:notPresent>
    --%>
    <h3><bean:message key="registrationForm.title"/>1222AAAAAAAAAAAAA</h3>
    <ul>
      <li><html:link action="Test.jsp">Test212121.jsp</html:link >
       <li><html:link action="/registration"><bean:message key="registrationForm.title"/></html:link></li>
       <%System.out.println("hellooooooooooooo");%>
       <!-- :TODO: Should have a non-JaveScript message-by-field example -->
       <li>
          <html:link action="/jsRegistration"><bean:message key="jsRegistrationForm.title"/></html:link> -
          <bean:message key="jsRegistrationForm.description"/>
       </li>
       <li>
          <html:link action="/multiRegistration"><bean:message key="multiRegistrationForm.title"/></html:link> -
          <bean:message key="multiRegistrationForm.description"/>
       </li>
    </ul>
    <a href="registration.jsp">Registration Test</a>
    <p> </p>
    <h3><bean:message key="typeForm.title"/></h3>
    <ul>
       <li>
          <html:link action="/type"><bean:message key="typeForm.title"/></html:link> -
          <bean:message key="typeForm.description"/>
       </li>
       <li>
          <html:link action="/editJsType"><bean:message key="jsTypeForm.title"/></html:link> -
          <bean:message key="jsTypeForm.description"/>
       </li>
    </ul>
    <p> </p>
    <h3>Change Language | Changez Le Langage</h3>
    <ul>
       <li><html:link action="/locale?language=en">English | Anglais</html:link></li>
       <li>
          <html:link action="/locale?language=fr">French | Francais</html:link> -
          <bean:message key="localeForm.fr"/>
       </li>
       <li>
          <html:link action="/locale?language=fr&country=CA">French Canadian | Francais Canadien</html:link> -
          <bean:message key="localeForm.frCA"/>
       </li>
       <li>
          <html:link action="/locale?language=ja" useLocalEncoding="true">Japanese | Japonais</html:link> -
          <bean:message key="localeForm.ja"/>
       </li>
    </ul>
    <p> </p>
    ==============struts-config.xml=================\<?xml version="1.0" encoding="iso-8859-1"?>
    <!DOCTYPE struts-config PUBLIC
    "-//Apache Software Foundation//DTD Struts Configuration 1.2//EN"
    "http://struts.apache.org/dtds/struts-config_1_2.dtd">
    <struts-config>
    <!--============================================== Form Bean Definitions -->
    <form-beans>
    <!-- Registration form bean -->
    <form-bean name="registrationForm" type="validator.RegistrationForm" />
    <!-- Multi-Part Registration form bean -->
    <form-bean name="multiRegistrationForm" type="validator.RegistrationForm" />
    <!-- Type form bean -->
    <form-bean name="typeForm" type="validator.TypeForm" />
    <!-- JavaScript Type form bean -->
    <form-bean name="jsTypeForm" type="validator.TypeForm" />
    </form-beans>
    <!-- ======================================== Global Forward Definitions -->
    <global-forwards>
    <forward name="home" path="/index.jsp" />
    </global-forwards>
    <!-- ========================================= Action Mapping Definitions -->
    <action-mappings>
    <action path="/welcome" forward="/index.jsp" />
    <!-- Registration Action
         -->
    <forward name="registration" path="/registration.do" /> //// ==========>here it is mapped
         <action path="/registration" forward="/registration.jsp" />
         <action path="/registration-submit" type="validator.RegistrationAction" name="registrationForm" scope="request" validate="true" input="input">
    <forward name="input" path="/registration.do" />
    <forward name="success" path="/index.jsp" />
    </action>
         <action path="/jsRegistration" forward="/jsRegistration.jsp" />
    <!-- Multi-Part Registration Action -->
    <action path="/multiRegistration" forward="/multiRegistration1.jsp" />
    <action path="/multiRegistration-submit" type="validator.MultiRegistrationAction" name="multiRegistrationForm" scope="request" validate="false">
    <forward name="success" path="/welcome.do" />
    <forward name="input1" path="/multiRegistration1.jsp" />
    <forward name="input2" path="/multiRegistration2.jsp" />
    </action>
    <!-- Type Action -->
    <action path="/type" forward="/type.jsp" />
    <action path="/type-submit" type="validator.TypeAction" name="typeForm" scope="request" validate="true" input="input">
    <forward name="input" path="/type.do" />
    <forward name="success" path="/welcome.do" />
    </action>
    <!-- JavaScript Type Action -->
    <action path="/editJsType" type="validator.EditTypeAction" scope="request" validate="false">
    <forward name="success" path="/jsType.do" />
    </action>
    <action path="/jsType" forward="/jsType.jsp" />
    <action path="/jsType-submit" type="validator.TypeAction" name="jsTypeForm" scope="request" validate="true" input="input">
    <forward name="input" path="/editJsType-submit.do?typeForm.reset=false" />
    <forward name="success" path="/welcome.do" />
    </action>
    <!-- Locale Action -->
    <action path="/locale" type="validator.LocaleAction" name="localeForm" scope="request">
    <forward name="success" path="/welcome.do" />
    </action>
    </action-mappings>
    <!-- ============================================= Controller Definition -->
    <controller inputForward="true" />
    <!-- ===================================== Message Resources Definitions -->
    <message-resources parameter="validator.MessageResources" />
    <!-- ============================================ Plug Ins Configuration -->
    <!--
    Add multiple validator resource files by setting the pathnames property
    with a comma delimitted list of resource files to load.
    -->
    <plug-in className="validator.ValidatorPlugIn">
    <set-property property="pathnames" value="/WEB-INF/validator-rules.xml,/WEB-INF/validator/validation.xml" />
    <set-property property="stopOnFirstError" value="true" />
    </plug-in>
    </struts-config>
    <html:img page="/struts-power.gif" altKey="index.powered"/>
    </body>
    </html:html>

    Hey,
    U can do it the way u want. Use DispatchAction Class instead of Action Class. Just go through the documentation for this. If u still have problem let me know.
    Thanks
    KM
    Hi,
    I am new to struts and when i am doing my application i find some >>difficulty i.e,
    I have two buttons on a jsp page Save,Delete.when I click on >>save ,saveAction must be called.if we click delete deleteAction to be >>called.
    for this how can I configure in struts-config.xml file. and how it >>knows which button has been clicked.
    Can any one please guid me.
    Thanks

  • 500 Internal Server Error when I add struts portlet in the portal

    I'm using jDeveloper 10g and have created a sample struts app which is working fine when using the regular struts-html.tld tags and struts-bean.tld tags .I'd like to get it working using the pdk-struts-html.tld taglib though so that I can deploy it as a portlet.
    When I run the jsp page as follow:
    <%@ taglib uri="/WEB-INF/pdk-struts-html.tld" prefix="pdk-struts-html"%>
    <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
    <%@ page contentType="text/html;charset=GBK"%>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=GBK">
    <title>untitled</title>
    </head>
    <body>
    <pdk-struts-html:errors />
    <pdk-struts-html:form action="/portal/SaveNewBlog.do">
    <bean:message key="userid.prompt"/>
    <pdk-struts-html:text property="userid" />
    <bean:message key="password.prompt"/>
    <pdk-struts-html:password property="password" />
    <pdk-struts-html:submit />
    </pdk-struts-html:form>
    </body>
    </html>
    However, there are some thing wrong with it ,I don't know how to modify it :
    500 Internal Server Error
    java.lang.NullPointerException
         at oracle.portal.provider.v2.url.UrlUtils.htmlFormActionLink(Unknown Source)
         at oracle.webdb.provider.v2.taglib.struts.html.PDKFormTag.renderFormStartElement(Unknown Source)
         at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:443)
         at oracle.webdb.provider.v2.taglib.struts.html.PDKFormTag.doStartTag(Unknown Source)
         at view.portal._enterNewBlog._jspService(enterNewBlog.jsp:11)
         [SRC:/view/portal/enterNewBlog.jsp]
         at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:139)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
         at oracle.security.jazn.oc4j.JAZNFilter.doFilter(Unknown Source)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:604)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:270)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
         at java.lang.Thread.run(Thread.java:534)
    Thanks
    yijv

    Sure ...
    <%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%>
    <%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html"%>
    <%@ page contentType="text/html;charset=windows-1252"%>
    <div>
        <html:errors/>
        <html:form action="/history.do">
          <input type="hidden" name="<c:out value='${bindings.statetokenid}'/>" value="<c:out value='${bindings.statetoken}'/>"/>
          <c:out value="${bindings.editingMode}" />
          <table border="0" cellpadding="2" cellspacing="0">
            <tr>
              <td>
                <c:out value="${bindings['SystemId'].label}"/>
              </td>
              <td>
                <html:text property="SystemId"/>
              </td>
              <td>
                <c:out value="${bindings['AlertTime'].label}"/>
              </td>
              <td>
                <html:text property="AlertTime"/>
              </td>
            </tr>
            <tr>
              <td>
                <c:out value="${bindings['ZoneName'].label}"/>
              </td>
              <td>
                <html:text property="ZoneName"/>
              </td>
              <td>
                <c:out value="${bindings['AlertCleared'].label}"/>
              </td>
              <td>
                <html:text property="AlertCleared"/>
              </td>
            </tr>
            <tr>
              <td>
                <c:out value="${bindings['AlertReason'].label}"/>
              </td>
              <td>
                <html:text property="AlertReason"/>
              </td>
              <td>
                <c:out value="${bindings['VesselImo'].label}"/>
              </td>
              <td>
                <html:text property="VesselImo"/>
              </td>
            </tr>
            <tr>
              <td> </td>
              <td> </td>
              <td>
                <c:out value="${bindings['VesselName'].label}"/>
              </td>
              <td>
                <html:text property="VesselName"/>
              </td>
            </tr>
          </table>
          <P>
            <input name="event_Search" type="submit" value="Search">
          </P>
        </html:form>
        <c:choose>
          <c:when test="${empty bindings.AlertHistoryView1.rangeSet}">No alerts matches your search criteria.</c:when>
          <c:otherwise>
            <table border="1" width="100%">
              <tr>
                <th> </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['SystemId']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['ZoneName']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['ValidFrom']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['ValidTo']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['Description']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['IsOpen']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['AlertReason']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['AlertTime']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['AlertLevel']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['AlertStatus']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['AlertCleared']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['VesselImo']}"/>
                </th>
                <th>
                  <c:out value="${bindings.AlertHistoryView1.labels['VesselName']}"/>
                </th>
              </tr>
              <c:forEach var="Row" items="${bindings.AlertHistoryView1.rangeSet}">
                <tr>
                  <td>
                    <c:out value="${Row.currencyString}"/>
                  </td>
                  <td>
                    <c:out value="${Row['SystemId']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['ZoneName']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['ValidFrom']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['ValidTo']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['Description']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['IsOpen']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['AlertReason']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['AlertTime']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['AlertLevel']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['AlertStatus']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['AlertCleared']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['VesselImo']}"/> 
                  </td>
                  <td>
                    <c:out value="${Row['VesselName']}"/> 
                  </td>
                </tr>
              </c:forEach>
            </table>
          </c:otherwise>
        </c:choose>
    </div>I'm trying with the DIV tags ... but no avail so far. It doesn't work without the DIV tags either.
    In regards to the stack trace - it's not in the application log, sorry - too many things going on this weekend ;) The stackdump goes to the browser ...
    java.lang.NullPointerException
         at oracle.portal.provider.v2.url.UrlUtils.htmlFormActionLink(Unknown Source)
         at oracle.webdb.provider.v2.taglib.struts.html.PDKFormTag.renderFormStartElement(Unknown Source)
         at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:511)
         at oracle.webdb.provider.v2.taglib.struts.html.PDKFormTag.doStartTag(Unknown Source)
         at _history._jspService(_history.java:62)
         [SRC:/history.jsp:6]
         at com.orionserver[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:782)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:330)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:226)
         at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
         at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:239)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:330)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:794)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:208)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:125)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.2.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
         at java.lang.Thread.run(Thread.java:534)

  • Taglib element not allowed in web.xml conforming to web-app_2_4.xsd ?

    Hello,
    I want to configure taglibs in my web.xml file.
    The beginning of the file looks like this:
    <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">I placed the following:      
    <taglib>
        <taglib-uri>/tags/struts-bean</taglib-uri>
        <taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
    </taglib>element just after the welcome-file-list element. When I "validate XML" in Netbeans I get :
    cvc-complex-type.2.4.a: Invalid content was found starting with element 'taglib'. One of '{"http://java.sun.com/xml/ns/j2ee":description, "http://java.sun.com/xml/ns/j2ee":display-name, "http://java.sun.com/xml/ns/j2ee":icon, "http://java.sun.com/xml/ns/j2ee":distributable, "http://java.sun.com/xml/ns/j2ee":context-param, "http://java.sun.com/xml/ns/j2ee":filter, "http://java.sun.com/xml/ns/j2ee":filter-mapping, "http://java.sun.com/xml/ns/j2ee":listener, "http://java.sun.com/xml/ns/j2ee":servlet, "http://java.sun.com/xml/ns/j2ee":servlet-mapping, "http://java.sun.com/xml/ns/j2ee":session-config, "http://java.sun.com/xml/ns/j2ee":mime-mapping, "http://java.sun.com/xml/ns/j2ee":welcome-file-list, "http://java.sun.com/xml/ns/j2ee":error-page, "http://java.sun.com/xml/ns/j2ee":jsp-config, "http://java.sun.com/xml/ns/j2ee":security-constraint, "http://java.sun.com/xml/ns/j2ee":login-config, "http://java.sun.com/xml/ns/j2ee":security-role, "http://java.sun.com/xml/ns/j2ee":env-entry, "http://java.sun.com/xml/ns/j2ee":ejb-ref, "http://java.sun.com/xml/ns/j2ee":ejb-local-ref, "http://java.sun.com/xml/ns/j2ee":service-ref, "http://java.sun.com/xml/ns/j2ee":resource-ref, "http://java.sun.com/xml/ns/j2ee":resource-env-ref, "http://java.sun.com/xml/ns/j2ee":message-destination-ref, "http://java.sun.com/xml/ns/j2ee":message-destination, "http://java.sun.com/xml/ns/j2ee":locale-encoding-mapping-list}' is expected. [53]
    cvc-complex-type.2.3: Element 'web-app' cannot have character [children], because the type's content type is element-only. [71]
    XML validation finished.Indeed, looking at the web-app_2_4.xsd I cannot find a description for the taglib element.
    Where should a put taglibs ? Is it enough to include them in every JSP so I don't need to place them in web.xml ?
    Thank you.
    Vlad.

    web.xml 2.4 uses a <jsp-config> to enclose the
    <tag-lib>
    <jsp-config>
    <tag-lib>
    </tag-lib>
    </jsp-config>I believe that is the syntax. I will check when I get
    to my server comp.You are right. That's how it's done. Thanks a lot for the reply.
    I hope there were good reasons to break compatibility with the old format. There are a lot of examples out there that use the old one. Without knowing the reason for such a change, I find it very annoying.
    Thanks again
    Vlad.

  • Error Using DOJO plug in with Struts 2 (for Ajax)

    Hi all,
    I am working on struts 2 and trying to use DOJO plug in for ajax.
    My JSP page is as follows
    +<%@ taglib prefix="s" uri="/struts-tags" %>+
    +<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>+
    +<html>+
    +<head>+
    +<sx:head/>+
    +</head>+
    +<body>+
    +<s:url id="url" value="/VarifyUserName.action" />+
    +<s:form name = "CreateUser" id = "CreateUser" action = "CreateUser.action">+
    +<s:div id="loginDiv" />+
    +<s:textfield name="username" id = "username" label = "UserName / EmailId" />+
    +<s:password name="password" id = "password" label = "Password" />+
    +<s:submit name="submit" id = "submit" value="submit" />+
    +<sx:bind id="ex3" href="%{#url}" sources="username" targets="loginDiv" events="onchange"+
    formId="CreateUser" />
    +</s:form>+
    +</body>+
    +</html>+
    This is just basic user registration page and I am checking for username duplication.
    Now the problem is page loads properly but in background it shows the error (Java Script error)
    Error: Could not locate widget implementation for "bindevent" in "struts.widget" registered to namespace "struts"
    and the Event I want to execute is not being executed.
    I have added jar file for DOJO.
    Please help me to solve this problem.
    Thanks in advance,
    Hirav OZa

    Place the plugin bundle, FlashAlbumexporter.ApertureExport, in your Aperture Export plugin directory (Users -> "your user name" -> Library -> Application Support -> Aperture -> Plug-Ins -> Export).
    NOTE: If this is your first Aperture plug-in, the folders Plug-Ins and Export may not exist. In this case just create them first.

  • Problem with struts-faces.jar

    hi,
    My requirement is to migrate a struts application to jsf.
    I am using the struts-faces.jar and doing all the configurations as mentioned.I am getting the following error while calling the application itself..
    java.lang.ClassNotFoundException: org.apache.struts.faces.taglib.LifecycleListener
    I am using the following version:
    1)Tried both struts-faces-0.4 and 0.3(downloaded from http://archive.apache.org/dist/struts/struts-faces/)
    2)Tomcat 5.0
    3)jsf-(SUN)
    4)struts 1.1
    Please let me know if i am doing something wrong. and any ways to fix this.
    Regards,
    Mythili

    Given the new release of the JSF ri and api .jar
    files,
    will this .jar provided at the apache site work?
    http://archive.apache.org/dist/jakarta/struts/old/relea
    e/struts-faces/
    No, those JARs only work with the EA versions of JavaServer Faces.
    A nightly build of the struts-faces integration library, that works with the beta release, is available at:
    http://cvs.apache.org/builds/jakarta-struts/nightly/struts-faces/
    and the corresponding source code is part of the Struts nightly build bundles in:
    http://cvs.apache.org/builds/jakarta-struts/nightly/src/
    in directory "contrib/struts-faces".
    This package is not yet ready to be released, but seems to work for me in all the cases where the old library worked before. (If you're migrating, note particularly some tweaks you need to add in the struts-config.xml file for the new version, documented in README.txt.) Work continues on the Tiles integration which feedback has indicated is really important to people.
    Developers who are building new components and renderers will be quite interested in the techniques used to make all the attributes of your own components value-binding-enalbled (like all the ones on the standard tags are). The source code for the <s:form> tag, plus the corresponding component and renderer, will be helpful in illustrating this.
    Craig McClanahan

  • Can't get definitions factory from context in struts tiles in weblogic 10

    I have exception trace which only happens whenever i recompiling my java file while running my web application in weblogic 10
    javax.servlet.ServletException: javax.servlet.ServletException: javax.servlet.jsp.JspException: Can't get definitions factory from context.
    *     at org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequestProcessor.java:286)*
    *     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)*
    *     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:449)*
    *     at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)*
    *     at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)*
    Caused by: javax.servlet.jsp.JspException: Can't get definitions factory from context.
    *     at org.apache.struts.tiles.taglib.InsertTag.processDefinitionName(InsertTag.java:580)*
    *     at org.apache.struts.tiles.taglib.InsertTag.createTagHandler(InsertTag.java:479)*
    *     at org.apache.struts.tiles.taglib.InsertTag.doStartTag(InsertTag.java:441)*
    Anybody has any idea how to fix this?
    It seems the error happen because weblogic trying to reload the context after i recompiling java file
    How do i turn off / workaround on this?
    By the way i m using struts tiles
    Thanks

    I have exception trace which only happens whenever i recompiling my java file while running my web application in weblogic 10
    javax.servlet.ServletException: javax.servlet.ServletException: javax.servlet.jsp.JspException: Can't get definitions factory from context.
    *     at org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequestProcessor.java:286)*
    *     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)*
    *     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:449)*
    *     at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)*
    *     at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)*
    Caused by: javax.servlet.jsp.JspException: Can't get definitions factory from context.
    *     at org.apache.struts.tiles.taglib.InsertTag.processDefinitionName(InsertTag.java:580)*
    *     at org.apache.struts.tiles.taglib.InsertTag.createTagHandler(InsertTag.java:479)*
    *     at org.apache.struts.tiles.taglib.InsertTag.doStartTag(InsertTag.java:441)*
    Anybody has any idea how to fix this?
    It seems the error happen because weblogic trying to reload the context after i recompiling java file
    How do i turn off / workaround on this?
    By the way i m using struts tiles
    Thanks

  • Java.lang.ClassCastException in struts application

    Hi,
    In application after I perform an insert(data into the DB) operation, the application must then display a list . Currently this is not happening. I can perform the insert operation successfully , but after that i get the following exception:
    java.lang.ClassCastException: org.theclass.candidate.view.SearchForm
         org.theclass.candidate.view.CandidateListAction.execute(CandidateListAction.java:41)
         org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:484)
         org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
         org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    I dont understand where to look for errors.
    This is my web.xml file :
    <web-app>
    <servlet>
    <servlet-name>action</servlet-name>
    <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
    <init-param>
    <param-name>config</param-name>
    <param-value>/WEB-INF/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>
    <init-param>
    <param-name>validate</param-name>
    <param-value>true</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
    </servlet>
    <!-- Standard Action Servlet Mapping -->
    <servlet-mapping>
    <servlet-name>action</servlet-name>
    <url-pattern>*.do</url-pattern>
    </servlet-mapping>
    <!-- The Usual Welcome File List -->
    <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
    <!-- Struts Tag Library Descriptors -->
    <taglib>
    <taglib-uri>/tags/struts-bean</taglib-uri>
    <taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-html</taglib-uri>
    <taglib-location>/WEB-INF/struts-html.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-logic</taglib-uri>
    <taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-nested</taglib-uri>
    <taglib-location>/WEB-INF/struts-nested.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-tiles</taglib-uri>
    <taglib-location>/WEB-INF/struts-tiles.tld</taglib-location>
    </taglib>
    </web-app>
    struts-config.xml:
    <struts-config>
         <form-beans>
              <form-bean
              name="candidateForm"
              type="org.theclass.candidate.view.CandidateForm"/>
         <form-bean
              name="listForm"
              type="candidate.ListForm"/>
              <form-bean
              name="searchForm"
              type="org.theclass.candidate.view.SearchForm"/>
         </form-beans>
    <global-forwards>
         <forward
              name="List"
              path="/jsp/list.jsp"/>
         <forward
              name="candidatelist"
              path="/CandidateList"/>
         <forward
              name="Add"
              path="/jsp/addcandidate.jsp"/>
    </global-forwards>
    <action-mappings>
         <action path="/Add"
              name="candidateForm"
              type="org.theclass.candidate.view.AddCandidateAction"
              validate ="true"
              input="/jsp/addcandidate.jsp">
              <forward name="success" path="/CandidateList.do"/>
         </action>
         <action path="/CandidateList"
              type="org.theclass.candidate.view.CandidateListAction"
              name="searchForm"
              scope="request" >
              <forward name="failure" path="/jsp/list.jsp"/>
              <forward name="success" path="/jsp/candidatelist.jsp"/>
         </action>
         <action path="/Edit"
              type="org.theclass.candidate.view.GetCandidateAction"
              name="candidateForm"
              scope="request"
              validate="false" >
              <forward name="success" path="/jsp/editcandidate.jsp"/>
              <forward name="error" path="/CandidateList.do"/>
         </action>
         <action path="/View"
              type="org.theclass.candidate.view.GetCandidateAction"
              name="candidateForm"
              scope="request"
              validate="false" >
              <forward name="success" path="/jsp/viewcandidate.jsp"/>
              <forward name="error" path="/CandidateList.do"/>
         </action>
         <action path="/EditCandidate"
              type="org.theclass.candidate.view.EditCandidateAction"
              name="candidateForm"
              scope="request"
              input="/jsp/editcandidate.jsp"
              validate="true" >
              <forward name="success" path="/CandidateList.do"/>
              <forward name="error" path="/jsp/editcandidate.jsp"/>
         </action>
         <action path="/ViewCandidate"
              name="candidateForm"
              scope="request"
              input="/jsp/viewcandidate.jsp"
              validate="true" >
              <forward name="success" path="/CandidateList.do"/>
              <forward name="error" path="/jsp/viewcandidate.jsp"/>
         </action>
    <action path="/List"
              name="searchForm"
              type="org.theclass.candidate.view.CandidateListAction"
              input="/jsp/list.jsp">
              <forward name="success" path="/jsp/candidatelist.jsp"/>
         </action>
    </action-mappings>
    <!-- Controller Configuration -->
    <controller
    processorClass="org.apache.struts.tiles.TilesRequestProcessor"/>
    <!-- Message Resources Definitions -->
    <message-resources parameter="ApplicationResources"/>
    <!-- comment following if struts1.0.x -->
    <plug-in className="org.apache.struts.tiles.TilesPlugin" >
    <set-property property="definitions-config"
         value="/WEB-INF/tiles-defs.xml" />
    <set-property property="moduleAware" value="true" />
    <set-property property="definitions-parser-validate" value="true" />
    </plug-in>
    <!-- end comment if struts1.0.x -->
         <plug-in className="org.apache.struts.validator.ValidatorPlugIn">
              <set-property property="pathnames" value="/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml"/>
    </plug-in>
    <plug-in className="org.theclass.candidate.view.HibernatePlugin">
    <!-- <set-property property="configFilePath" value="/WEB-INF/src/hibernate.cfg.xml" /> -->
         <set-property property="configFilePath" value="/hibernate.cfg.xml" />
    <set-property property="storeInServletContext" value="true" />
         </plug-in>
    </struts-config>
    Please tell me where am i going wrong. I am running out of time.
    I use struts 1.2.9, JDK 5,tomcat 5.5.17. In CandidateListAction class i have hibernate query language statements(HQL)

    Take a look at the stack trace, it shows you exactly where the error is coming from:
    java.lang.ClassCastException: org.theclass.candidate.view.SearchForm
    org.theclass.candidate.view.CandidateListAction.execute(CandidateListAction.java:41)Line 41 in your CandidateListAction.
    Probably it is failing on a cast of your action form.
    Taking a closer look at your struts-config, you are "chaining" actions.
    Your AddCandidateAction uses the candidateForm, and forwards to CandidateListAction.do
    Your CandidateListAction uses the searchForm.
    That will be the cause of your class cast exception.
    <action path="/Add"
      name="candidateForm"
      type="org.theclass.candidate.view.AddCandidateAction"
      validate ="true"
      input="/jsp/addcandidate.jsp">
      <forward name="success" path="/CandidateList.do"/>
    </action>
    <action path="/CandidateList"
    type="org.theclass.candidate.view.CandidateListAction"
    name="searchForm"
    scope="request" >
    <forward name="failure" path="/jsp/list.jsp"/>
    <forward name="success" path="/jsp/candidatelist.jsp"/>
    </action>Check out: http://struts.apache.org/1.x/faqs/newbie.html#chaining
    Solutions?
    - don't chain actions ;-)
    - use the same action form for both actions (possible?)
    - make the actionForward a "redirect" one. That means a new request, and losing any request parameters/attributes but should prevent this class cast exception.
    Hope this helps,
    evnafets

  • Struts to jsf

    In struts there is the applicationResources.properties file. Is there a corresponding properties file for jsf, or is all the information maintained in the Backing Bean??

    Hi, after further research, the information is located under Using Localized Messages, the objects are called "ResourceBundles", instead of the struts bean, "<%@ taglib uri="/tags/struts-bean" prefix="bean" %> which is defined by <!-- ==== Message Resources Definitions -->
    <message-resources parameter="ApplicationResources" null="false"></message-resources>

  • JSR 168 and Struts support sample error

    I'm trying to get the sample webapp for JSR 168 and Struts support working with
    WebLogic 8.1, and I'm having problems with the struts portlet. The other portlets
    seem to work fine, but the Struts portlet gives the following error after clicking
    "Save" on most of the forms:
    Page Flow Error - Action Not Found
    Page Flow: Global.app
    Action: html-setters.do
    Unable to find action html-setters.do.
    That error appears in the browser. At the same time, the following exception
    appears in the server window:
    <Aug 18, 2003 4:34:12 PM EDT> <Error> <netui> <BEA-420012> <There was an error
    while running a lifecycle stage :: Lifecycle: UIControl.render :: for the control
    :: null ::.
    com.bea.netuix.nf.UIControlException: For portlet [strutsPortlet], could not do
    page flow lookup for the given action [html-setters.do] in the given PageFlow:
    [struts/exercise-taglib].
    This exception is followed by hundreds of lines of the following:
    at com.bea.wlw.netui.pageflow.scoping.ScopedServletUtils.strutsLookup(ScopedServletUtils.java:363)
    as well as several stack overflow errors.
    I believe I have installed the JSR168 and Struts support package according to
    the instructions, and have copied the required jars into the samples WEB-INF/lib
    directory. I also have tried to write my own Struts application in a portlet,
    and it gets the exact same errors when I try to submit a form to my actions.
    Any insight would be much appreciated!
    Thanks,
    Patrick

    Hi Brodi,
    I am having the same problem as Patrick. The problem is not in the struts portlet,
    but in the forms the portlet navigates to. After the struts portlet loads, I
    am able to use the html:links and navigate through the pages. Though when I try
    to submit a form I get the action not found error. For example the html-select
    page has a form. This page loads fine, but when I hit the save button I get the
    following error.
    <Aug 25, 2003 11:00:00 AM EDT> <Error> <netui> <BEA-420012> <There was an error
    while running a lifecycle stage :: Lifecycle: UIControl.render :: for the contro
    l :: null ::.
    com.bea.netuix.nf.UIControlException: For portlet [strutsPortlet], could not do
    page flow lookup for the given action [html-select.do] in the given PageFlow:
    struts/exercise-taglib].
    The application appears to loose the struts context. It tries to find the localhost:7001/samples/html-select.do
    action instead of localhost:7001/samples/struts/exercise-taglib/html-select.do
    action. How do I keep the application from loosing context?
    Thank you,
    Karen
    "Brodi Beartusk" <[email protected]> wrote:
    >
    Patrick-
    I've seen similar things happen when the module name is either not specified
    correctly
    in the StrutsContent element in the portlet, or when the module is misconfigured,
    usually because of either a mising config file or a mis-named config
    file.
    Ensure that you have a the struts config file for the exercise-taglib
    module in
    WEB-INF, named jpf-struts-config-struts-exercise-taglib.xml.
    -Brodi Beartusk
    "Patrick Callis" <[email protected]> wrote:
    I'm trying to get the sample webapp for JSR 168 and Struts support working
    with
    WebLogic 8.1, and I'm having problems with the struts portlet. Theother
    portlets
    seem to work fine, but the Struts portlet gives the following errorafter
    clicking
    "Save" on most of the forms:
    Page Flow Error - Action Not Found
    Page Flow: Global.app
    Action: html-setters.do
    Unable to find action html-setters.do.
    That error appears in the browser. At the same time, the followingexception
    appears in the server window:
    <Aug 18, 2003 4:34:12 PM EDT> <Error> <netui> <BEA-420012> <There was
    an error
    while running a lifecycle stage :: Lifecycle: UIControl.render :: for
    the control
    :: null ::.
    com.bea.netuix.nf.UIControlException: For portlet [strutsPortlet], could
    not do
    page flow lookup for the given action [html-setters.do] in the given
    PageFlow:
    [struts/exercise-taglib].
    This exception is followed by hundreds of lines of the following:
    at com.bea.wlw.netui.pageflow.scoping.ScopedServletUtils.strutsLookup(ScopedServletUtils.java:363)
    as well as several stack overflow errors.
    I believe I have installed the JSR168 and Struts support package according
    to
    the instructions, and have copied the required jars into the samples
    WEB-INF/lib
    directory. I also have tried to write my own Struts application ina
    portlet,
    and it gets the exact same errors when I try to submit a form to myactions.
    Any insight would be much appreciated!
    Thanks,
    Patrick

  • I am getting problem in struts

    Dear Friends,
    I am getting the follwing error while using strust so please help me on this topic
    org.apache.jasper.JasperException: File "/WEB-INF/tags/struts-bean" not found
    at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:94)
    at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:365)
    at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:151)
    at org.apache.jasper.compiler.TagLibraryInfoImpl.(TagLibraryInfoImpl.java:182)
    at org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:456)
    at org.apache.jasper.compiler.Parser.parseDirective(Parser.java:517)
    at org.apache.jasper.compiler.Parser.parseElements(Parser.java:1567)
    at org.apache.jasper.compiler.Parser.parse(Parser.java:174)
    at org.apache.jasper.compiler.ParserController.parse(ParserController.java:254)
    at org.apache.jasper.compiler.ParserController.parse(ParserController.java:154)
    at org.apache.jasper.compiler.ParserController.parse(ParserController.java:140)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:250)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:458)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:444)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:603)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:300)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:293)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:286)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:562)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:974)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:205)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:562)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:974)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:177)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
    at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:149)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:149)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:562)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:974)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:156)
    at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:562)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:974)
    at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:203)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:637)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:488)
    at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:568)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:631)
    at java.lang.Thread.run(Unknown Source)

    If you feel everything is correctly set including the folder structure.
    It;d be gr8 if you can post only tld configurations made in web.xml and if you are using web.xml Servlet 2.4+ specification don't forget to enclose all the configuration under <jsp-config> tags something like the one below
    <jsp-config>
         <taglib>
            <taglib-uri>/WEB-INF/tags/struts-bean</taglib-uri>
            <taglib-location>/WEB-INF/tags/struts-bean.tld</taglib-location>
          </taglib>
    </jsp-config>Hope that might help :)
    REGARDS,
    RaHuL

  • Exception while running STRUTS application???

    HI,
    This is my 2nd post regarding my struts application, previous error was solved, but when i'm tryin to run my application with tomcat i'm getting error(plz help me tellin what changes i've to do in my application).It is actually the first page of the application which is a simple index.jsp, from where i've links to other main pages.The error i'm getting is:-
    HTTP Status 500 -
    type Exception report
    message
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:372)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    java.lang.NullPointerException
    org.apache.struts.util.RequestUtils.computeURL(RequestUtils.java:521)
    org.apache.struts.util.RequestUtils.computeURL(RequestUtils.java:436)
    org.apache.struts.taglib.html.LinkTag.calculateURL(LinkTag.java:495)
    org.apache.struts.taglib.html.LinkTag.doStartTag(LinkTag.java:353)
    org.apache.jsp.index_jsp._jspx_meth_html_link_0(index_jsp.java:96)
    org.apache.jsp.index_jsp._jspService(index_jsp.java:69)
    org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    note The full stack trace of the root cause is available in the Apache Tomcat/5.0.27 logs.
    Apache Tomcat/5.0.27

    Here i'm posting my index.jsp(where link tag is used), search.jsp, web.xml and struts.xml.frm index.jsp i just want to go to search.jasp frm where all the real thing will start.plz have look on all these files and let me no where i'm wrong.
    index.jsp :-
    <%@ page langiuage="java" %>
    <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
    <html>
    <head>
    <title>Gaurav, Human Resource Portal</title>
    <head>
    <body>
    <font size="+1"><b>Gaurav Human Resource Portal</b></font><br>
    <hr wodth="100%" noshade="true">
    &#149; Add an Employee<br>
    &#149;<html:link forward="search">Search for Employees</html:link><br>
    </body>
    </html>
    search.jsp :-
    <%@ page language="java" %>
    <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
    <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
    <%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
    <html>
    <head>
    <title>Gaurav, Human Resource Portal</title>
    </head>
    <body>
    <font size="+1"><b>Gaurav, Human Resource Portal - search.jsp</b></font>
    <hr width="100%" noshade="true">
    <html:errors/>
    <html:form action="/search">
         <table>
              <tr>
                   <td align="right"><bean:message key="label.search.name"/>:</td>
                   <td><html:text property="name"/></td>
              </tr>
              <tr>
                   <td></td>
                   <td>--- or ---</td>
              </tr>
              <tr>
                   <td align="right"><bean:message key="label.search.ssNum"/>:</td>
                   <td><html:text property="ssNum"/> (xxx-xx-xxxx)</td>
              </tr>
              <tr>
                   <td></td>
                   <td><html:submit/></td>
              </tr>
         </table>
    </html:form>
    <logic:present name="searchForm" property="results">
         <hr width="100%" size="1" noshade="true">
         <bean:size id="size" name"searchForm" property="results"/>
              <logic:equal name="size" value="0">
                   <center><font color="red"><b>No Employees Found</b></font></center>
              </logic:equal>
              <logic:greaterThan name="size" value="0">
                   <table border="1">
                        <tr>
                             <th>Name</th>
                             <th>Social Security number</th>
                        </tr>
                        <logic:iterate id="result" name="searchForm" property="results">
                        <tr>
                             <td><bean:write name="result" property="name"/></td>
                             <td><bean:write name="result" property="ssNum"/></td>
                        </tr>
                        </logic:iterate>
                   </table>
              </logic:greaterThan>
    </logic:present>
    </body>
    </html>
    web.xml :-
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
    "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
    <web-app>
    <display-name>Gaurav MiniHR Portal</display-name>
    <!-- Standard Action Servlet Configuration (with debugging) -->
    <servlet>
    <servlet-name>action</servlet-name>
    <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
    <init-param>
    <param-name>config</param-name>
    <param-value>/WEB-INF/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>
    <!-- Standard Action Servlet Mapping -->
    <servlet-mapping>
    <servlet-name>action</servlet-name>
    <url-pattern>*.do</url-pattern>
    </servlet-mapping>
    <!-- The Usual Welcome File List -->
    <welcome-file-list>
    <welcome-file>/index.jsp</welcome-file>
    </welcome-file-list>
    <!-- Struts Tag Library Descriptors -->
    <taglib>
    <taglib-uri>/tags/struts-bean</taglib-uri>
    <taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-html</taglib-uri>
    <taglib-location>/WEB-INF/struts-html.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-logic</taglib-uri>
    <taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-nested</taglib-uri>
    <taglib-location>/WEB-INF/struts-nested.tld</taglib-location>
    </taglib>
    <taglib>
    <taglib-uri>/tags/struts-tiles</taglib-uri>
    <taglib-location>/WEB-INF/struts-tiles.tld</taglib-location>
    </taglib>
    </web-app>
    struts-config.xml :-
    <?xml version="1.0" encoding="ISO-8859-1" ?>
    <!DOCTYPE struts-config PUBLIC
    "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN"
    "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">
    <struts-config>
         <!-- ==========Form Beans configuration section.(i.e ActionForm objects)========== -->
         <form-beans>
              <form-bean name="searchForm" type="com.jamesholmes.minihr.SearchForm" />
    </form-beans>
    <global-forwards>
              <forward name="search" path="/search.jsp" />
    </global-forwards>
    <!-- =================================== Action Mapping Definitions -->
    <action-mappings>
              <action path="/search"
                        type="com.jamesholmes.minih.SearchAction"
                        name="searchForm"
                        scope="request"
                        validat="true"
                        input="/search.jsp"
              </action>
    </action-mappings>
    <!-- ================================ Message Resources Definitions -->
    <message-resources parameter="com.jamesholmes.minihr.ApplicationResources"/>
    </struts-config>

  • Struts message-resource problems in jboss

    Hi,
    I'm fairly new to jsp/servlets and I'm trying to use the struts framework.
    I have a html file with the struts bean taglib defined and the following line :
    <bean:message key="index.title" />
    In struts-config.xml I have the following :
    <message-resources parameter="MyAppResources" />
    And I put MyAppResources.properties in WEB-INF/classes
    I then add the files to myapp.war and deploy it in jboss, but when I try to load the page I get the following exception :
    javax.servlet.ServletException: Cannot find message resources under key org.apache.struts.action.MESSAGE
    Any help would be greatly appreciated!!!

    and if, after deploying, you delete the war file? Does it work then?
    Problem seems to be that in a war file the directories arent as the class loader expects them, I think.

Maybe you are looking for

  • Read the manual; still can't get it right

    i've followed instructions on setting path and classpath, but still can't get the HelloWorldApp to work right. it makes the .class file fine but the java HelloWorldApp command gives this to stdout Exception in thread "main" java.lang.NoClassDefFoundE

  • Nested for-each not working

    Hello all. I am studying XSLT in school and need some help. Display the following: Software titles for each operating system sorted by category. Sorting is not the problem. I am having an issue with displaying software titles for each operating syste

  • Message Type ( Idoc Type ) for customer master & Pending invoice

    Hi My Client is doing sale in POS for credit customers and credit customer master should be sent to POS as outbound Idoc. 1.What is the standard message type for sending Customer masters to POS. WP_PER01 is not activated for  version 700 ( message  g

  • How to load pdf in flex application for android os

    I loaded pdf in stagewebview which works good in IOS but not in android. The pdf file is loaded from the application storage directory. Please help me in resolving the problem. Thank you in advance.

  • Compiling a driver, need assistance on kernel source configuration

    Hello BBS. I am compiling a module for the Asus PCE N53 wireless pci-e card. I have obtained the driver source, and followed the instructions, and have gotten to the point where I need assistance. The instructions requires the kernel source, i have s