Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

use of javascript in struts

 
Prams Coolkarni
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys, i have been working on struts recently and using some javascript for the validation process of certain fields. I wanted to know that how can we get the value of indexId specified in the given <logic:iterate> tag of struts in javascript so that, that value can be used by me in the javascript for my validation logic.
 
SuprajaY Yasoda
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
think it helps

alert(document.FBRePre["arrSelectedAO["+i+"]"][document.FBITT["arrSelectedAO["+i+"]"].selectedIndex].value)


FBRePre is name of the form
arrSelectedAO is name of the field in form
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic