It is question on portlet pdk struts tags link

hi:
<td>
<jsp:useBean id="rowEditSet" class="java.util.HashMap"/>
<c:set target="${rowEditSet}" property="event" value="setCurrentRowWithKey"/>
<c:set target="${rowEditSet}" property="Arg0" value="${Row.rowKeyStr}"/>
<pdk-html:link action="/browseCustomers.do" name="rowEditSet">Select
</pdk-html:link>
result:
Select
dont use

The problem was an old copy of the struts.jar file, which was missing the calculateUrl() method called by the Oracle tag. With a new struts.jar file, all was good.

Similar Messages

  • PDK Struts tags

    When trying to use the PDK Struts tags in a portlet, I receive the following error message when the portlet has been deployed to a 10g portal:
    [ServletException in:/WEB-INF/jsp/tiles/portal/index.jsp] action'
    Even with debug mode enabled on the server, that's the only detail I get. My config is as follows:
    IN SERVER.XML
    <taglib>
    <taglib-uri>/WEB-INF/tld/pdk-struts-html.tld</taglib-uri> <taglib-location>/WEB-INF/tld/pdk-struts-html.tld</taglib-location>
    </taglib>
    IN THE TAGLIB INCLUDE
    <%@ taglib uri='/WEB-INF/tld/pdk-struts-html.tld' prefix='pdk' %>
    IN THE JSP:
    <pdk:link page="/servlet/letterView">Link text</pdk:link>
    VERIFIED:
    - The portlet works without the tag included.
    - It works using the standard Struts html:link tag, but of course generates the resulting page in it's own screen, outside of the portal container
    - The TLD is indeed in the location listed in the URI
    - The following two JARs are included in the LIB directory: pdkjava.jar, pdkstruts.jar
    - I removed all attributes from the tag and received a more detailed message (Cannot create rewrite URL: java.net.MalformedURLException: You must specify exactly one of "forward", "href", or "page"') so it seems like everything that needs to be in place is indeed in place -- it seems like I'm just misusing the tag.
    Any help would be appreciated. Thanks!

    The problem was an old copy of the struts.jar file, which was missing the calculateUrl() method called by the Oracle tag. With a new struts.jar file, all was good.

  • How to use pdk-struts-html:link

    i have a portlet,
         <pdk-html:link href="/StartEhrpHrj.do?targetGroup=Hrj1030MInfDtlGroup">
                   xyz
    </pdk-html:link> </td>
    but no link,why

    Hi,
    It is not an issue with the tag. Look at the docs for the struts html:link tag; the pdk-html:link tag is intended to replace this tag and not the regular HTML anchor tag.
    Good luck,
    Hernando
    hjbconsulting at comcast dot net

  • Pdk struts jsp tags not working.

    The problem we have hited is that pdk-struts tags are not rendered corectly:
    From next piece of code:
    <pdk-html:form action="/auth_portlet/doLogin.do" name="loginFormBean" type="passport_portlets.auth_portlet.loginFormBean">
    <%--<pdk-html:errors/>--%>
    <table width="100%" cellpadding="0" cellspacing="0" border="0">
    <tr>
        <td>Username:</td>
        <td><pdk-html:text property="username"/></td>
    </tr>
    <tr>
        <td>Password:</td>
        <td><pdk-html:text property="password"/></td>
    </tr>
    <tr>
        <td></td>
        <td><pdk-html:submit value="Login"/></td>
    </tr>
    </table>
    </pdk-html:form>We recieve next output in the browser window:
    <form name="loginFormBean" method="post" action="/passport_portlets/auth_portlet/doLogin.do">
    <table width="100%" cellpadding="0" cellspacing="0" border="0">
    <tr>
        <td>Username:</td>
        <td><input type="text" name="username" value=""></td>
    </tr>
    <tr>
        <td>Password:</td>
        <td><input type="text" name="password" value=""></td>
    </tr>
    <tr>
        <td></td>
        <td><input type="submit" value="Login"></td>
    </tr>
    </table>
    </form>But it's wrong output, there aren't any qualifiing naming prossed, as much as no hidden fields included into form. We don't receive any kind of errors, just such simple output in browser.

    to be more detailed and specific, source follows
    provider.xml
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <?providerDefinition version="3.1"?>
    <provider class="oracle.portal.provider.v2.DefaultProviderDefinition">
       <session>true</session>
       <passAllUrlParams>false</passAllUrlParams>
       <portlet class="oracle.portal.provider.v2.DefaultPortletDefinition">
          <id>1</id>
          <name>AuthPortlet</name>
          <title>portlet name</title>
          <description>description</description>
          <timeout>40</timeout>
          <showEditToPublic>false</showEditToPublic>
          <hasAbout>false</hasAbout>
          <showEdit>false</showEdit>
          <hasHelp>false</hasHelp>
          <showEditDefault>false</showEditDefault>
          <showDetails>false</showDetails>
          <renderer class="oracle.portal.provider.v2.render.RenderManager">
             <renderContainer>true</renderContainer>
             <renderCustomize>true</renderCustomize>
             <autoRedirect>true</autoRedirect>
             <contentType>text/html</contentType>
             <showPage class="oracle.portal.provider.v2.render.http.StrutsRenderer">
             <defaultAction>/auth_portlet/doDefault.do</defaultAction>
             </showPage>
          </renderer>
       </portlet>
    </provider>
    web.xml
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
        <description>web.xml file for passport portlets package</description>
      <context-param>
        <param-name>oracle.portal.log.LogLevel</param-name>
        <param-value>4</param-value>
      </context-param>
      <servlet>
        <servlet-name>SOAPServlet</servlet-name>
        <servlet-class>oracle.webdb.provider.v2.adapter.SOAPServlet</servlet-class>
      </servlet>
      <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>
        <load-on-startup>1</load-on-startup>
      </servlet>
      <servlet-mapping>
        <servlet-name>SOAPServlet</servlet-name>
        <url-pattern>/providers</url-pattern>
      </servlet-mapping>
      <servlet-mapping>
        <servlet-name>SOAPServlet</servlet-name>
        <url-pattern>/providers/*</url-pattern>
      </servlet-mapping>
      <servlet-mapping>
        <servlet-name>action</servlet-name>
        <url-pattern>*.do</url-pattern>
      </servlet-mapping>
        <session-config>
            <session-timeout>35</session-timeout>
        </session-config>
        <mime-mapping>
            <extension>html</extension>
            <mime-type>text/html</mime-type>
        </mime-mapping>
        <mime-mapping>
            <extension>txt</extension>
            <mime-type>text/plain</mime-type>
        </mime-mapping>
    </web-app>
    struts-config.xml
    <?xml version="1.0" encoding="windows-1251" ?>
    <!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>
        <form-bean name="loginFormBean"
                   type="passport_portlets.auth_portlet.loginFormBean">
          <form-property name="username" type="java.lang.String"/>
          <form-property name="password" type="java.lang.String"/>
        </form-bean>
      </form-beans>
      <action-mappings>
        <action path="/auth_portlet/doDefault"
                type="passport_portlets.auth_portlet.doDefaultAction">
          <forward name="loged" path="/auth_portlet/showLoginState.jsp" redirect="true"/>
          <forward name="notloged" path="/auth_portlet/showLoginForm.jsp" redirect="true"/>
        </action>
        <action path="/auth_portlet/doLogin"
                type="passport_portlets.auth_portlet.doLoginAction"
                name="loginFormBean"
                scope="request"
                validate="true"
                input="/auth_portlet/showLoginForm.jsp">
          <forward name="success" path="/auth_portlet/showLoginState.jsp" redirect="true"/>
          <forward name="failure" path="/auth_portlet/showLoginForm.jsp" redirect="true"/>
        </action>
      </action-mappings>
      <message-resources parameter="passport_portlets.ApplicationResources"/>
    </struts-config>
    showLoginForm.jsp
    <%@ page contentType="text/html;charset=windows-1251"%>
    <%@ taglib uri="http://xmlns.oracle.com/portal/pdk/struts/tags-html" prefix="pdk" %>
    <pdk:xhtml/>
    <pdk:form action="/auth_portlet/doLogin.do" name="loginFormBean" type="passport_portlets.auth_portlet.loginFormBean" method="post">
    <table width="100%" cellpadding="0" cellspacing="0" border="0">
    <tr>
        <td>Username:</td>
        <td><pdk:text property="username"/></td>
    </tr>
    <tr>
        <td>Password:</td>
        <td><pdk:text property="password"/></td>
    </tr>
    <tr>
        <td></td>
        <td><pdk:submit value="Login"/></td>
    </tr>
    </table>
    </pdk:form>all works fine, except the problem that pdk-struts tags in jsp page aren't processed correctly, they output simple html output, which is not formated to inline rendering rules (qualified naming of fields, hidden fields with all values, etc).
    Maybe I'm missing something?

  • PDK-Struts Application requires pdkstruts.jar & pdk-struts-html.tld

    Hi All,
    Scenario is this, that I've created a pdk-struts application via JDeveloper with normal struts taglibs, and deployed it to Oracle Portal 10.1.4. default-action tags specified action.do is working fine and displays the welcome page within portlet region but after clicking any button within that welcome page opens a new browser page within same window and the URL pattern changes too.
    I want this to be executed within portlet region.
    Another problem is this, when I tried to use pdk-struts-html.tld within application;
    first warning within JDeveloper is this; Metadata Namespace for pdk-struts-html is not loaded, all entries are fine, and within Portal after successful deployment it gives an error (500 Server Listener Error) on viewing that portlet body.
    I want these issues to be resolved as soon as possible.
    Or if anybody knows about pdkstruts.jar and pdk-struts-html.tld with latest versions, plz do tell me the site-url to download these things.
    Plz help me out about these issues.
    Thanks in advance.

    Look in the Building Struts Portlets with Oracle Jdevelper section of the Oracle Application Server Portal Developers Guide. You need additional jar files besides the pdkstruts one. Also, look in the server logs to see more detailed messages about why it failed, it will help you debug.

  • Unwanted behavior in PDK struts

    Hi,
    I am facing some peculiar problem. I have one portlet. That portlet has one anchor link. on click of that link opens another popup window where I have my struts portlet added. In the newly opened portlet i have one text box where ReservationId is input. If I input that Id and perform it is going to next screen. The problem is if I close that popup page and click on the parent page it will again open that window and showing a validation message(Reservation Id is required). I didn't understand one thing. I am not submitting any form. But by clicking on the link(on parent window) why form is getting submitted automatically to struts. Any Idea?
    Regards,
    Reddi

    I too have the same problem....
    the portlet was working fine, till i added a "pdk-html:file" tag and changed the enc-type to multipart/form-data.
    when ever the form is submited, the message is shown "Portlet Unavailable".
    I noticed that... even the execute method is not called on form submission.
    Please... help.

  • JDeveloper 10.1.3.2 pdk-struts taglib doesn't work

    Hi all,
    I just installed new jDev version (10.1.3.2) and I migrated all projects and setting from 10.1.3.1, but I still got a little/big problem with PDK-Struts taglib.
    In the previous jDev version portlet add-in wasn't include and to use pdk-struts integrate in the IDE I managed it as a JSP TagLib and everythings works fine.
    In new version the taglib in native and ready (it doesn't required to be registered!) to use but when I'm building the project I found and exception
    Error: java.lang.NoClassDefFoundError: org/apache/struts/taglib/html/FormTag
    mind!!!
    - the same project in version 10.1.3.1 has no problem to build
    - I checked and seleted all the libraries required
    Anyone knows why the new jDev version doesn't work??
    please someone helpMe!!!!
    Regards
    spig@

    Yea, I had those "is not a registered namespace in TLD" errors too, but regarding Struts HTML... I had to go to the Project properties and add the library.. (It went missing during conversion)
    Its frustrating and I know how you feel. Try this, try that and still doesnt work. My advice is to remove taglibs. Close Jdev. Open Jdev add them again. It have to work. Also it might help to delete class directories. Also be aware that some libraries are kept in "\WEB-INF\lib" and during conversion they remained (those libraries were from old Jdev you have to replace them with new version)
    So, all in all keep tryng, it have to work :)
    Good luck...

  • Struts tag for request.setAttribute() in a jsp page

    Hello All
    Does anyone know struts tag that can be used for request.setAttribute() in a jsp page?
    Thanx in advance.

    Well
    <bean:define id="foo" name="newsIdAttribute" scope="request" type="java.lang.String" />is equivalent to
    <%
    (java.lang.String) foo = (java.lang.String)request.getAttribute("newsIdAttribute");
    %for setting bean properties you might have to use
    <jsp:setProperty/> or <c:set/> tags in JSP / JSTL respectively.
    Hope this might answer your question :)
    REGARDS,
    RaHuL

  • JDeveloper editing JSP with Struts tags terribly, terribly slow!?

    I use JDeveloper 10.1.2 and I do not know the reason but it started to take 15min just to change/edit JSP containing Struts tags. RAM memory is 1GB and there is more than 0.5 GB available, but processor usage shows 100% allocated to JDeveloper!? As soon as I do even slight change in a JSP file JDeveloper starts some computations and I have no idea of what it is doing.
    What is JDeveloper computing? It seems it tries to produce some drop-down lists "helping" me to do the editing, add tags and instead I am spending days to just change one small JSP page!
    How can I stop and PREVENT JDeveloper doing ANY "help" during editing of ANY file?
    There must be an option to switch off whatever JDeveloper is doing?
    Many thanks,

    I did that but it is still very slow, it looks like Jdev is doing some intensive calculations whenever I click somewhere on JSP page with tags. Maybe this is related with my other question I posted before this one? Maybe JDev automatically searches for tag libraries it cannot find and copies them to /WEB-INF directory? (other IDEs used in same environment, like Eclipse and IntelliJ, and they do not have this problem)
    Some other strange things: struts-config.xml seems not integrated with CVS from JDev (other files like tiles-config.xml, web.xml etc. are integrated, I can right click and get CVS info on particular file, except struts-config.xml). When I want to check in/out struts-config.xml I have to do it with external tool like WinCVS etc., cannot do that from JDev!

  • PDK Struts HTML API Listing

    Hi,
    Can you guide me in locating the PDK Struts HTML API listing, i am unable to find any documentation regarding these tags and how they can be used.
    Any pointers to some detailed documentation on these tags would be greatly
    appreciated!!
    Thanks,
    Srikarthik

    Srikarthik ,
    There is not a seperate doc for the Struts API. As far as I can tell, the basis of these tags are Struts 1.1. You can find documentation on Struts 1.1 at http://struts.apache.org//struts-doc-1.1/index.html . Please be aware that there apparently are some limitations compared to normal struts. According to metalink note #357760., the hidden and textareas values are lost on submit.
    Eric

  • PDK Struts Not calling StrutsAction

    Hello,
    I posted this question in portal-general forum and just now found out this specific forum.
    My PDK-struts implementation JSP doesn't seem to invoke the Struts-Action class at all after the submit button is clicked on the JSP Page. I just modified the JPDK-struts sample to call my specific action class. The only difference is I use local copy of pdk-struts.tld vs. the external uri used in the jsps of the sample. Any idea? Thanks.

    Hello,
    I posted this question in portal-general forum and just now found out this specific forum.
    My PDK-struts implementation JSP doesn't seem to invoke the Struts-Action class at all after the submit button is clicked on the JSP Page. I just modified the JPDK-struts sample to call my specific action class. The only difference is I use local copy of pdk-struts.tld vs. the external uri used in the jsps of the sample. Any idea? Thanks.

  • How to prepare Custom tag with scope as  session  like Struts tag

    Hi
    All Struts tags having the feature of Automatic Scoping.
    Automatic Scoping: Struts tags check all contexts (namely page, request, session, application) and use the first instance found. Developers do not have to explicitly "retrieve" objects from a particular scope. They may, however, specify a context.
    same as like struts tag I want to preapre 'select custom tag'.which will retrieve its previous selected value automatically and display.And one important thing is I dont want to set the selected value of custom tag in session expicitly.I mean the custom tag it self should take care to set the session vale and retrieve the sesion value and display like Struts tag . For struts select tag we wont set any selected value in session though it will retrieve the previous value and display when scope of form = session
    regards
    jagan

    Hi
    All Struts tags having the feature of Automatic Scoping.
    Automatic Scoping: Struts tags check all contexts (namely page, request, session, application) and use the first instance found. Developers do not have to explicitly "retrieve" objects from a particular scope. They may, however, specify a context.
    same as like struts tag I want to preapre 'select custom tag'.which will retrieve its previous selected value automatically and display.And one important thing is I dont want to set the selected value of custom tag in session expicitly.I mean the custom tag it self should take care to set the session vale and retrieve the sesion value and display like Struts tag . For struts select tag we wont set any selected value in session though it will retrieve the previous value and display when scope of form = session
    regards
    jagan

  • Passing struts-tag value to java / javascript variable in JSP

    Hello all,
    Im trying to pass the value got from the struts-tag to the java variable in the Jsp. However Im not able to get the o/p. Can u guys help me on this pls...
    <logic:notEmpty name="TreeBean" property="list">
        <logic:iterate id="Type" name="TreeBean" property="list" indexId="i">
         <br/><bean:write name="Type" />
        </logic:iterate>
    </logic:notEmpty>Here the list can be populated in the jsp page. However i want the values into jsp list. Im not able to populate the same..
    <% List jspList = null;
    %> I want the values into the jspList variable for further processing. Can u guz pls help me on this....

    Which do you want it in?
    A java variable for use in <% scriptlet code %> or a javascript variable for use on the client end?
    scriptlet:
    <jsp:useBean id="TreeBean" type="java.util.List" class="java.util.ArrayList" scope="?????" />
    Having scriptlet code on the page is considered bad coding style.
    What is it you are trying to accomplish by making the value accessible?
    What are you trying to do in java / javascript that can't be done with JSP tags?

  • Struts tag problems in weblogic 5.1 sp12

              Hello,
              I am deploying a struts application in weblogic 5.1 sp 12. When I load any jsp
              page with a struts tag, e.g. <html:html>, it will throw exceptions as follows:
              Parsing of JSP File '/Feedback.jsp' failed:
              /Feedback.jsp(-1): Error in tag library at: 'bean': error introspecting class:
              'org.apache.struts.taglib.bean.CookieTag': weblogic.servlet.jsp.JspException:
              (line -1): Error in tag library at: 'bean': class org.apache.struts.taglib.bean.CookieTag
              doesn't implement javax.servlet.jsp.tagext.Tag
              probably occurred due to an error in /Feedback.jsp line -1:
              any comment is highly appreciated! I am following the directions posted on apache
              website about instaling struts with weblogic 5.1.
              

              Hello,
              I am deploying a struts application in weblogic 5.1 sp 12. When I load any jsp
              page with a struts tag, e.g. <html:html>, it will throw exceptions as follows:
              Parsing of JSP File '/Feedback.jsp' failed:
              /Feedback.jsp(-1): Error in tag library at: 'bean': error introspecting class:
              'org.apache.struts.taglib.bean.CookieTag': weblogic.servlet.jsp.JspException:
              (line -1): Error in tag library at: 'bean': class org.apache.struts.taglib.bean.CookieTag
              doesn't implement javax.servlet.jsp.tagext.Tag
              probably occurred due to an error in /Feedback.jsp line -1:
              any comment is highly appreciated! I am following the directions posted on apache
              website about instaling struts with weblogic 5.1.
              

  • Problem compling JSP with struts tags on Weblogic 8.1

    I have deployed a web application in Weblogic 8.1. However, I am facing a problem while the JSPs are getting compiled. The JSPs ahve taglib declarations referring to Struts tag library files that are present in WEB-INF folder.
    Stacktrace:
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\myserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209: cannot resolve symbol
    probably occurred due to an error in /approve/approve_home.jsp line 53:
    <logic:notPresent name="<%=JobBean.ID%>" scope="request">
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\myserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209: cannot resolve symbol
    symbol : variable EVAL_BODY_BUFFERED
    location: interface javax.servlet.jsp.tagext.BodyTag
    if (_int0 == BodyTag.EVAL_BODY_BUFFERED) { //[ /approve/approve_home.jsp; Line: 53]
    I believe other people have also faced this issue with Weblogic8.1 and struts. Any solutions???
    Thx
    KP

    KP,
    Does this code run in the development environment but not in production? How
    was this code compiled?
    - john
    "KP" <[email protected]> wrote in message
    news:405b9b56$[email protected]..
    I have deployed a web application in Weblogic 8.1. However, I am facing aproblem while the JSPs are getting compiled. The JSPs ahve taglib
    declarations referring to Struts tag library files that are present in
    WEB-INF folder.
    Stacktrace:
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\m
    yserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209:
    cannot resolve symbol
    probably occurred due to an error in /approve/approve_home.jsp line 53:
    <logic:notPresent name="<%=JobBean.ID%>" scope="request">
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\m
    yserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209:
    cannot resolve symbol
    symbol : variable EVAL_BODY_BUFFERED
    location: interface javax.servlet.jsp.tagext.BodyTag
    if (_int0 == BodyTag.EVAL_BODY_BUFFERED) { //[/approve/approve_home.jsp; Line: 53]
    >
    I believe other people have also faced this issue with Weblogic8.1 andstruts. Any solutions???
    >
    Thx
    KP

Maybe you are looking for