Cant get the javascript function "whichElement(e)" to work in JSP out.println();

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Aliraza Zaidi
    New Member
    • Nov 2010
    • 1

    #1

    Cant get the javascript function "whichElement(e)" to work in JSP out.println();

    Code:
     out.println("<li><a onclick=\'javascript:whichElement(e);menuClicked();selectMenu("+orders.get(i).toString().substring(43)+","+orders.get(i).toString().substring(39,40)+")\'>"+orders.get(i).toString().substring(0,37)+"</a></li>");
  • JKing
    Recognized Expert Top Contributor
    • Jun 2007
    • 1206

    #2
    Is that a user defined function?

    Comment

    • Ali Zaidi

      #3
      yes this is a user defined function.

      Comment

      • JKing
        Recognized Expert Top Contributor
        • Jun 2007
        • 1206

        #4
        Do the other functions in the string work?

        Does the function work outside of a println?

        Could you post the code for the function?

        Are there any javascript errors on the page?

        Comment

        Working...