Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2004
    Location
    Madurai, Tamilnadu, India
    Posts
    9

    Unanswered: Gettting records inside select box

    I need to load a field retrieved from a database into a select box. How can i do it. I need the code.

  2. #2
    Join Date
    Feb 2002
    Location
    San Francisco, CA
    Posts
    441
    You mean you need to populate a select box with values from a database?

  3. #3
    Join Date
    Jan 2004
    Location
    Madurai, Tamilnadu, India
    Posts
    9
    Yes, I need to populate the select with the content of a database

  4. #4
    Join Date
    Feb 2002
    Location
    San Francisco, CA
    Posts
    441
    Code:
    'open rs
    %>
    <select name="selecty thing">
    <%
    while not rs.eof
    %>
    <option value="<%=rs.fields("id")%>"><%=rs.fields("text")%></option>
    <%
    rs.movenext
    wend
    %>
    </select>
    <%
    'close rs

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •