Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Getting a sheet to use and remember the Date and Time input types

Hi folks, I've got the following HTML- <!--div class="sheet-events"> <h1 class="sheet-section">Events</h1> <fieldset class="repeating_events"> <table> <tbody> <tr> <th width="1%"></th> <td style="text-align:top"> <label>Description: <textarea rows="4" cols="15" name="attr_EventDescription"></textarea></label> </td> <td><label>Date: <input type="date" name="attr_EventDate"></td></label> <td><label>Time: <input type="time" name="attr_EventTime"></td></label> <td style="text-align:top"> <label>Location: <textarea rows="4" cols="15" name="attr_EventLocation"></textarea></label> </td> <td style="text-align:top"> <label>Duration: <input name="attr_EventDuration" type="text"/></label> </td> <td style="text-align:top"> <label>Notes: <textarea rows="4" cols="20" name="attr_EventNotes"></textarea></label> </td> </tr> </tbody> </table> </fieldset> </div--> The text based fields all work just fine. The data entered is remembered. But the Date and Time fields are not, and I can't see what I'm doing wrong. Anyone know what I'm messing up here?
1699414426

Edited 1699415380
vÍnce
Pro
Sheet Author
Hi Tuck. Roll20 probably does not allow input types "date" and "time".  Using type="text" should be fine.  If you are worried about the format, sheetworkers could be used to check user input.  You could also use title and/or placeholder text to help demonstrate how the data should be input. p.s I will not mention the use of tables for sheet layout in roll20 ... I won't. ;-P
1699424356

Edited 1699456782
GiGs
Pro
Sheet Author
API Scripter
Vince is correct, Roll20 doesn't support Date and Time fields. You best bet is saving them as text, or using three number fields (one each for day, month, and year, and then putting them together in a readonly text display field if needed). For time, probably 2 number inputs, one for hours and one for minutes (and maybe a third for seconds if that level of precision is needed).
thanks. I was really hoping to use the cool calendar and time inputs that those functions bring. Nevermind. Thanks for the corrections though.