This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I am using a select list in my form where the user can choose an item from the list and I want the parameter to be the ID number of their selection. Am I doing this correctly? When I print out my the parameter in my servlet it comes back null.
Whether <c:forEach>, or any other JSP component, is used in a form or not is completely moot. Anything that's not a JSP mechanism is simply template text, and the JSP engine could care less what it is. It could be an HTML form, or the Gettysburg Address, or the result of your pet iguana walking across the keyboard.
What you need to make sure of is that the resulting HTML is valid. Yours is not. Why is the select element outside the form?
You must also create the HTML that does what you want. This is completely independent of JSP. So if you want the select element to participate in the form submission, it must inside the form and have a name.
And if you want the submitted value of the selected option to be something other than its display text, you must use the value attribute.
That's all just basic HTML concepts. Don;t get confused by the fact that the HTML is being generated by a JSP. In the end, it's just an HTML page like any other that is sent to the browser.