February 27th, 2002, 10:10 AM
date and time
I have a html form and a jsp page saving the information added in the form to the database. What I want to do in my jsp page is when I am recieving the parameters from the html page I want to generate the date and the time and save them as strings seperately into my database along with the rest of my strings. Is this possible?
March 1st, 2002, 08:22 AM
Yeah. You can either use the database to generate them, or you can do Calendar.GetInstance(), and then use all the get methods on it to construct a string of the format you want.
Important Note: for some obscure reason january is month 0 not month 1 and it counts from there, which is very weird, but was the same in the Date class aswell. You'd have thought that they'd do it for days of the month too, but no...they come out completley fine!