Results 1 to 2 of 2
  1. #1
    01r207 is offline Member
    Join Date
    Oct 2011
    Posts
    1
    Rep Power
    0

    Default How to use var from bean in function?

    I want to use data from Bean(list of string[]) in my function, but no matter how I write it doesnt want to work.My code

    XML Code:
    <c:forEach var="sport" items="${sports.data}" >
        <% myFunction(sport[0]) %>      
        ${sport[0]} //this prints on website correct data 
    </c:forEach>

    How can I do anything with data from bean in jsp?

  2. #2
    unaTRASotra is offline Member
    Join Date
    Nov 2011
    Posts
    5
    Rep Power
    0

    Default Re: How to use var from bean in function?

    try with semicolon:

    <% myFunction(${sport}); %>

Similar Threads

  1. To pass bean property values to a javascript function and generate dojo datagrid.
    By Chinnu55 in forum JavaServer Pages (JSP) and JSTL
    Replies: 1
    Last Post: 11-13-2011, 04:06 PM
  2. Replies: 1
    Last Post: 03-23-2011, 08:55 AM
  3. UREGENT-accessing session bean ok but entity bean
    By parimal in forum Enterprise JavaBeans (EJB)
    Replies: 1
    Last Post: 08-28-2008, 02:34 PM
  4. Replies: 0
    Last Post: 03-30-2008, 11:03 AM
  5. Replies: 0
    Last Post: 09-26-2007, 09:36 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •