Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

There was a problem

You must be a member of this account.

Javascript Date/Time Picker

#92

The date/time selection boxes on content/new should be replaced with a javascript calendar that has intelligent defaults.

Reported by Brian Michalski · June 6th, 2010 @ 02:19 PM

State: resolved
Milestone: none
Assigned to: Haris Khan Haris Khan

Activity

  1. Brian Michalski
    Brian Michalski
    • Tag changed from calendar, upload, v2 to calendar, html5, upload, v2

    I've done some playing around with HTML 5 elements for storing a datetime (input type="datetime") which semantically is what we want (I think). Unfortunately, the user interface is dreadful at the moment, the spec requires the field contain values like "1990-12-31T23:59:60Z" which is a really hard format for anyone to type from memory. Opera 9+ provides a built in date & time picker to help select a value, but all the other browsers just render a text box. I haven't seen any signs of support coming soon from other browsers.

    There are some javascript libraries that will enhance a type="date" field to use a pretty date picker, but I haven't seen any JS libraries to enhance the markup of a datetime box.

    This leads me a few ideas:
    1. Ignore semantics and just use a type="text" box.
    2. Use type="datetime" and write some JS to merge in with one of the date pickers.
    3. Use both type="date" and type="time" boxes, kind of like Concerto 1. We could mark them up independently.

    June 22nd, 2010 @ 04:34 PM

  2. Brian R Zaik
    Brian R Zaik
    • State changed from new to open
    • Assigned user set to Brian R Zaik
    • Milestone order changed from 0 to 0

    We did something like this for the Locale project I worked on last semester at RPI. We basically had separate date and time pickers and merged the selections into a single datetime object. I believe the merge was done in Ruby (I have code lying around for this somewhere).

    I have attached an L2 mockup of Add Graphics Content. Under Basic Details, you can see separate selectors for date and time. Basically, I wanted to default the time to 12:01 am / 11:59 pm like we did in Concerto 1, and allow users to click the button to select both date and time. We can have nice selectors for each. Then we just merge the result together into a datetime object and store it.

    August 15th, 2010 @ 10:38 PM

  3. Brian R Zaik
    Brian R Zaik

    This time picker looks to have a pretty interesting approach: http://haineault.com/media/jquery/ui-timepickr/page/ (jQuery.timepickr).

    We could easily integrate it with the design from above. We could pair it with a basic jQuery UI calendar widget.

    August 16th, 2010 @ 01:31 PM

  4. Brian Michalski
    Brian Michalski

    I think that looks pretty cool, it might work well if it activated when you
    clicked on clock icon.

    The HTML5 attributes let us have an input type=time that would be bound to
    something like that, and an input type=date to handle the date selector. I
    don't know if we want to go down this route, but we could explore only
    displaying the JS pickers iff the browser doesn't have it's own picker.
    (More info at http://diveintohtml5.org/forms.html#type-date)

    August 16th, 2010 @ 01:44 PM

  5. Haris Khan
    Haris Khan
    • Assigned user changed from Brian R Zaik to Haris Khan

    September 25th, 2010 @ 05:11 PM

  6. Haris Khan
    Haris Khan

    Progress is being made, decided not to go the route of html5.

    http://senatedev.union.rpi.edu/khanh/concerto2/content/new

    So far...

    October 25th, 2010 @ 01:51 AM

  7. Haris Khan

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.