Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Quotation marks when mixing jsp and html forms

Reply
Thread Tools

Quotation marks when mixing jsp and html forms

 
 
deepstar@gmail.com
Guest
Posts: n/a
 
      11-15-2005
Hey all

I'm trying to generate one list item per Sql row, but the code instead
generates four individual droplists containing one item each. Any ideas
on what might be wrong?

ResultSet rslt = addStmt.executeQuery("SELECT name FROM topic");
ResultSetMetaData rsmd = rslt.getMetaData();

for (int i = 1; i <= rsmd.getColumnCount(); i++) {

while(rslt.next()) {
String getTopic = rslt.getString(i);
getTopic = rslt.getString("name");
%>

<H3>Available topics:</H3>
<br/>
<form METHOD"POST" ACTION="mockup.jsp">
<select size="1" name="view">
<option value="yes"><% out.println(getTopic);%></option>

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Searching for a Firefox extension involving quotation marks Teh Suck Firefox 0 01-17-2006 09:00 AM
Using quotation marks Radith Java 1 01-07-2005 12:59 AM
String and quotation marks M. Clift Python 2 10-22-2004 09:01 PM
Question about concatenating quotation marks Peng Yu C Programming 3 10-02-2004 08:08 PM
<q> and language-specific quotation marks Tristan Miller HTML 54 11-06-2003 05:19 PM



Advertisments