file included with jsp:include doesn't get parameters

Discussion in 'Java' started by ittay.dror@gmail.com, Dec 7, 2005.

  1. Guest

    Hi,

    I have this example (jsp 2.0):

    some_file.jsp:
    .....
    <c:forEach items="${myItems}" var="foo">
    ${foo} <!-- works fine -->
    <jsp:include page="mypage.jsp"/>
    </c:forEach>

    mypage.jsp:
    ${foo}


    the expression in mypage doesn't evaluate to any value. i used c:eek:ut
    and got the same results, and foo is there for sure in some_file.jsp.

    i also tried to include from a tag, using pageContext.include(), same
    result

    i guess i can pass parameters to mypage.jsp using 'param', but i don't
    want to do that, in the real case that i have (i want to pass
    everything to this page, because i use this include generically in many
    places, and using different pages)

    i can (and prefer) to do it from a tag

    thanx
    ittay
    , Dec 7, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    1
    Views:
    417
    Patrick
    Apr 22, 2004
  2. Per Magnus L?vold
    Replies:
    2
    Views:
    1,328
    Per Magnus L?vold
    Aug 30, 2004
  3. Replies:
    0
    Views:
    4,328
  4. Andreas Bogenberger
    Replies:
    3
    Views:
    881
    Andreas Bogenberger
    Feb 22, 2008
  5. Vojma

    Include file in another included file

    Vojma, Nov 30, 2003, in forum: ASP General
    Replies:
    6
    Views:
    157
    Stefan Lundberg
    Dec 2, 2003
Loading...

Share This Page