In my form i want a date field and a time field to be populated with current date and time as default. How do i do that?
Then i have a second datetime field. In the form i want to have a text field (or a dropdown maybe) in which i type in a time differens in minutes, in relation to the first field, and the result to be stored in the second datetime field.
That sounds messy, here’s and example:
First datetime field: 2014-06-07 23:00
Text field: 10 (this is a time differens in minutes)
Result stored in second datetime field in the db table: 2014-06-07 22:50
Does it make any sense?
Should i be considering another db backend instead of the standard one in base when dealing with different timestamps? Like “created at”, “updated at” and so on?
Thanks!
/Göstapopoulos