Originally posted by K Robert:
should I capture this is a variable name or is this acceptable?
I do not understand your question because you're not being very precise. What kind of variable are you talking about? Client-side or server-side?
Secondly, if I wanted to perform an if/else inside this function and on a particular value, do I just wrap the value in an if/else in side the getInfo()? Or, do I create an in-body <script> to run the logic there?
Again, not clear. You wouldn't nest a <script> tag inside another. Are youtalking about a client-side conditional, or a server-side conditional? If the former, just use the JavaScript if statement. Why the confusion?
If it's the mixing of JSP with JavaScript that's confusing you. Just remember that any JSP elements will be evaluated on the server in order to format an HTML page to be sent to the browser. So any part of the page that's not a JSP element gets treated just like any other old-fashioned HTML page.