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

    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="${}" >
        <% myFunction(sport[0]) %>      
        ${sport[0]} //this prints on website correct data 

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

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

    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, 03:06 PM
  2. Replies: 1
    Last Post: 03-23-2011, 07: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, 01:34 PM
  4. Replies: 0
    Last Post: 03-30-2008, 10:03 AM
  5. Replies: 0
    Last Post: 09-26-2007, 08: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