Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

clock form

Status
Not open for further replies.

gsc123

Programmer
Jan 24, 2008
197
i want to add the date and time to a database from a form so it needs to be a selectable time and date, is there anything out their to use to pick date and time?
 
Should this be in html forum>?
 
not sure if this is what you meant, but you can create a for loop to populate the [tt]select[/tt] field with hours and then another one for minutes.
example for minutes:
Code:
<select id="mm">
  <option value="0">00</option>
  <%
    ' if you want to increment by certain amounts
    ' add step 5 or whatever number you want to the first line
    for i = 0 to 59
    x = x + 1
    if x < 10 then
    x = "0" & x
    end if
  %>
    <option value="<%=x%>"><%=x%></option>
  <%
    next
  %>
</select>

as for the date selection, you can use the same method or find a calendar script using your favourite search engine!

________________________________
Top 10 reasons to procrastinate:
1)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top