Struts 1
  1. Struts 1
  2. STR-1301

<nested:iterate> loses index with jsp:include

    Details

    • Type: Bug Bug
    • Status: Reopened
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 1.1.0
    • Fix Version/s: Future
    • Component/s: Tag Libraries
    • Labels:
      None
    • Environment:
      Operating System: Windows XP
      Platform: PC

      Description

      POTENTIAL BUG:
      When using nested:interate and placing a jsp:include in the iteration, the
      included jsp cannot retrieve the proper nesting level. Thus any form related
      nested tags are possibly named with duplicate names. ie:

      <input hidden="name[0]" value="name1"/>
      <input hidden="name[0]" value="name2"/>

      COMMENT OF NOTE:
      It appears that tag does NOT lose the actual underlying beans,
      it just loses the proper naming of the index.

      SIMPLE EXAMPLE:

          • testNestedIterate.jsp =
            <nested:root name="narray">
            <nested:iterate property="names">
            BEFORE: <nested:writeNesting /><br />
            <jsp:include page="testNestedIterateInclude.jsp" />
            </nested:iterate>
            </nested:root>
          • testNestedIterateInclude.jsp =
            <nested:root>
            AFTER: <nested:writeNesting />
            Name in bytes: <nested:write property="bytes"/><p />
            </nested:root>

      I will attach the test class throwaway.test.Names
      in a subsequent comment to help document this problem better.
      I've tried to seriously test this before submitting this as
      bug so if any further information is needed please reach me
      at cbutler@mateso.com.

      1. ASF.LICENSE.NOT.GRANTED--testNestedIterateInclude2.jsp
        0.1 kB
        Chris Butler
      2. ASF.LICENSE.NOT.GRANTED--testNestedIterateInclude.jsp
        0.3 kB
        Chris Butler
      3. ASF.LICENSE.NOT.GRANTED--testNestedIterateInclude.jsp
        0.7 kB
        Chris Butler
      4. ASF.LICENSE.NOT.GRANTED--testNestedIterate.jsp
        0.5 kB
        Chris Butler
      5. ASF.LICENSE.NOT.GRANTED--testInnerTwo.jsp
        0.3 kB
        Christine
      6. ASF.LICENSE.NOT.GRANTED--testInnerOne.jsp
        0.8 kB
        Christine
      7. ASF.LICENSE.NOT.GRANTED--testInnerJunk.jsp
        0.2 kB
        Christine
      8. ASF.LICENSE.NOT.GRANTED--testBase.jsp
        0.4 kB
        Christine
      9. ASF.LICENSE.NOT.GRANTED--StrutsInnerBean.java
        1 kB
        Christine
      10. ASF.LICENSE.NOT.GRANTED--StrutsBaseForm.java
        2 kB
        Christine
      11. ASF.LICENSE.NOT.GRANTED--requestScope.jsp
        1 kB
        Chris Butler
      12. ASF.LICENSE.NOT.GRANTED--Names.java
        0.3 kB
        Chris Butler

        Issue Links

          Activity

          Chris Butler created issue -
          Don Brown made changes -
          Field Original Value New Value
          issue.field.bugzillaimportkey 17977 26592
          Anonymous made changes -
          Link This issue blocks STR-1530 [ STR-1530 ]
          Don Brown made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          David Evans made changes -
          Status Closed [ 6 ] Reopened [ 4 ]
          Assignee Struts Developer Mailing List [ dev@struts.apache.org ]
          Ted Husted made changes -
          Bugzilla Id 17977
          Fix Version/s TBD [ 21701 ]
          Fix Version/s 1.2 Family [ 21693 ]
          Jeff Turner made changes -
          Project Import Mon Feb 01 01:03:21 UTC 2010 [ 1264986201992 ]
          Mark Thomas made changes -
          Workflow jira [ 12490510 ] Default workflow, editable Closed status [ 12545792 ]
          Mark Thomas made changes -
          Workflow Default workflow, editable Closed status [ 12545792 ] jira [ 12549099 ]
          Mark Thomas made changes -
          Workflow jira [ 12549099 ] Default workflow, editable Closed status [ 12559198 ]
          Mark Thomas made changes -
          Workflow Default workflow, editable Closed status [ 12559198 ] jira [ 12587631 ]
          Gavin made changes -
          Link This issue blocks STR-1530 [ STR-1530 ]
          Gavin made changes -
          Link This issue is depended upon by STR-1530 [ STR-1530 ]

            People

            • Assignee:
              Unassigned
              Reporter:
              Chris Butler
            • Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:

                Development