I find it odd that input type="date"
is still not supported in Firefox after all of this time. In fact, I don't think they added in much (if any) of the HTML 5 new types on an input element. Not surprised that it is not supported in IE10. So, my question is...
How to get type="date"
on an input
element working without adding, yet another, .js file (namely jQueryUI
DatePicker Widget) just to get a calendar/date for only IE and Firefox Browsers? Is there something out there that can be applied somewhere (CDN perhaps?) that will make this functionality work by default in Firefox and/or IE Browsers?? Trying to target IE 8+ Browsers and for Firefox, doesn't matter, newest version (28.0) will be fine.
UPDATE: Firefox 57+ supports input type=date
There's a simple way to get rid of this restriction by using the datePicker component provided by jQuery.
Include jQuery and jQuery UI libraries (I'm still using an old one)
Use the following snip
See jQuery UI DatePicker - Change Date Format if needed.
You can try webshims, which is available on cdn + only loads the polyfill, if it is needed.
Here is a demo with CDN: http://jsfiddle.net/trixta/BMEc9/
In case the default configuration does not satisfy, there are many ways to configure it. Here you find the datepicker configurator.
Note: While there might be new bugfix releases for webshim in the future. There won't be any major releases anymore. This includes support for jQuery 3.0 or any new features.
Here is the proper solution. You should use jquery datepicker everywhere
Below is the link to get the complete code
https://tutorialvilla.com/how/how-to-solve-the-problem-of-html-date-picker
It is in Firefox since version 51 (January 26, 2017), but it is not activated by default (yet)
To activate it:
about:config
dom.forms.datetime -> set to true
https://developer.mozilla.org/en-US/Firefox/Experimental_features
The latest version of firefox the firefox 57(Quantum) supports date and other features it was released on November 14, 2017. You can download it by clicking this link
Sometimes you do not want use Datepicker http://jqueryui.com/datepicker/ in your project because:
Please see my very simple cross browser code for date input. My code apply only if your browser is not supports the date type input