LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 07-14-2005, 06:49 AM   #1
nimishabhatia
LQ Newbie
 
Registered: Jan 2005
Location: india
Posts: 2

Rep: Reputation: 0
How To Put Values In Select Box From Database In Jsp


hi everybody,

I wanted to know if we could place <options> values in a selct box from teh database in jsp?
i am using postgresql7.4 as my database and hv the connectivity via the jdbc driver.
thanx in advance
Regards
Nimisha
 
Old 07-20-2005, 01:16 PM   #2
traene
Member
 
Registered: Jan 2005
Distribution: Archlinux, Debian, Centos
Posts: 222

Rep: Reputation: 35
Maybe if you place the jsp tag right after the select box in your webpage, like:

Code:
<form>
<input type="select">
<% generateSelectContent(); %>
</form>
The genrateSelectContent(); prints the html tags for the select content:
<OPTION name="option1" value="1">
and so on...
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Microsoft access database, jsp and DSN Anxo Linux - Software 1 08-17-2005 04:43 PM
for loop inside select box opioid Programming 1 03-17-2005 02:22 PM
Changing a table contents dynamically based on select box rose_bud4201 Programming 4 01-13-2005 10:48 AM
Select Box, PHP agallant Programming 8 08-04-2004 01:15 PM
How do I select a row of info in a database file? 1rulesall Linux - Newbie 6 12-08-2003 08:27 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 02:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration