Populating my dropdown menu from MySQL database using jsp

I my database i have a table of users and i want everytime a user is added the dropdown menu gets updated, this is make updating of user's profile easy. I tried the one bellow but still get me 80 errors:

-connection String

<select name="userName" id="userName">

<% for(int i=1; i<=resultsList; ++i){%>

<option value="<%=out.println(rs.getUserName(1))%>"><%=out.println(rs.getUserName(1))%></option>

<option value="<%=out.println(rs.getUserName(i))%>"><%=out.println(rs.getUserName(i))%></option>

<%}%>

</select>

Pls i need help

[625 byte] By [Nino@Polya] at [2007-11-27 11:34:31]
# 1

80 errors, you say?

I'm not a fan of writing muddled jsp pages that refer to the database layer. If you're willing to learn JSF or some other web framework, you'll being able to write better code and never use a scriptlet again.

BigDaddyLoveHandlesa at 2007-7-29 16:57:41 > top of Java-index,Java Essentials,Java Programming...