Here's what I came up with:

In my jsp:
<%@ page import="myclasses.Finals" %>
<script type="text/javascript" language="javascript">
  <%@ include file="myscript.js" %>
</script>

In myscript.js:
function myFunction()
{
  if (formAction == "<%= Finals.RESET %>")
  {
    // reset the page, etc.
  }
}

The only problem that I can see is that this sort of defeats one of the 
purposes for having functions in an external file: hiding your 
javascript code. I'm not sure how big of an issue that is because you 
can find the .js file in cache anyway.

Thanks for all of the help!

Jason



To change your membership options, refer to:
http://www.sys-con.com/java/list.cfm

Reply via email to