Replacing JHtml::_('calendar', ...) with a fresh JQuery.UI.Datepicker !

3,627 views
Skip to first unread message

Marc Studer

unread,
Aug 17, 2012, 11:50:13 AM8/17/12
to joomla-...@googlegroups.com
As you may know, the Joomla API to display calendar is based on the DynCalendar JS API.
This API is used since Joomla 1.0 and seems to have never really change ... since 2005 !?
For the developpers, this API is very poor, give so few parameters and will get some CSS trouble under IE browsers (IE9).

With the arrival of Joomla 3.0 with Bootstrap and JQuery, we have 2 new and fresh Datepickers coming !

- JQuery Datepicker demo : http://jqueryui.com/demos/datepicker/
- Bootstrap Datepicker demo : http://www.eyecon.ro/bootstrap-datepicker/

Bootstrap-Datepicker (is not attached to the twitter bootstrap's project) seems to have less display type and parameters than the JQuery one. it has been reported that the bootstrap-datepicker is a stand alone project and may not be compatible with some version of Bootstrap (like the version 2.0.2) and some browser like IE7+ (corrections has been made on a fork of this project (http://aymkdn.github.com/Datepicker-for-Bootstrap).

The JQuery Datepicker has a wide wide list of configurable parameters and a wide type of rendering (simple date, inline display, range of date, multiple months display ...).
One objectif may be to keep the actual API instanciation with JHtml::_('calendar', + parameters) to have backwards compatibility.
We can used the last parameters to pass HTML parameters (such as display types).
And we may need to add a new last parameter as 'jsattribs' to pass javascript attribs to the datepicker.
To make it works we have to add ressources in Joomla 3.0 as :
- datepicker.js
- css and images of necessary icons not currently added in joomla

We have try (one dev from Hikashop team 'Jerome' and i) to replace DynCalendar with the Datepicker of Bootstrap.
The datepicker solution seems to work perfectly and may be used by developpers with no change.

Based on a 3.0 alpha 2, we have actually modify the behavior.calendar and the JHtml::_('calendar', ...) and it works pretty good.

We are going to publish some information about our work :
- a google doc to explain our choice and proposal (the media/jui structure may need some changes !?)
- a joomla 3.0 Alpha 2 test site to show result and power of the JQuery Datepicker : see http://dev.joomla.fr/datepicker/ 
- We are preparing a submit on the bugtracker for this feature and to post our patchs.

We have a lot of works to do more to add the very huge list of Options for Datepicker ( http://jqueryui.com/demos/datepicker/#options ), but it seems to be a good solution to add a great calendar solution to Joomla.

We also have begin to write an explanation content of the use and configuration of this DatePicker.
If this patch is committed to Joomla, this article will be linked to http://docs.joomla.org/JHTML::calendar (for a 12.? link)

What do you think about this ?
Any suggestions or modifications needed ?
How can we proceed to deliver this patch ? by patch files on the bug tracker ?

Kind regards,
Marc STUDER (aka Garstud)

Rouven Weßling

unread,
Aug 17, 2012, 12:20:19 PM8/17/12
to joomla-...@googlegroups.com
I'd love to get rid of the antique but your opening a can of worms. I back around 1.7 I tried updating it to a much more modern (Mootools) datepicker but finally had to give up due to the lack of support for non-gregorian calendars.

I suggest you talk to JM, he has more details what has to happen so we can get to a new calendar.

Best regards
Rouven
 
--
You received this message because you are subscribed to the Google Groups "Joomla! CMS Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-cms/-/tR3VfXHpdJoJ.
To post to this group, send an email to joomla-...@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-cm...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/joomla-dev-cms?hl=en-GB.

Marc Studer

unread,
Aug 17, 2012, 12:54:04 PM8/17/12
to joomla-...@googlegroups.com
Thanks, yes you're right, i was just discussing with JM, and he explains me the complexity about Farsi/Persian and Hebreu... with the translation of the numbers in each date !
 
I understand, that it will be the same as the work done on calendar-setup.js and localize.php.
We can not integrate the Datepicker without modify its code and do the same ... so i think it may be impossible to integrate it before the release of 3.0 Beta 1 !?

But i don't want to stop this work, DynCalendar needs really to be changed ... in a not far future, perhaps ?

Thank you

Michael Babker

unread,
Aug 17, 2012, 1:39:29 PM8/17/12
to joomla-...@googlegroups.com
Perhaps you could start work now and we could add it as a feature in 3.1 in March?  This gives time to really make the changes and test it across environments instead of trying to rush the work and get it in within the next couple of weeks.

--
You received this message because you are subscribed to the Google Groups "Joomla! CMS Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-cms/-/Aadf6d6R_U0J.

Marc Studer

unread,
Aug 17, 2012, 1:46:20 PM8/17/12
to joomla-...@googlegroups.com
Sure, that was exactly, what we're thinking about ;)
- v3.1 : target initialized !
 
We just have to understand the mass work done on Farsi/Persian now ... ouch ! :)

Javier Gómez

unread,
Aug 17, 2012, 4:50:31 PM8/17/12
to joomla-...@googlegroups.com
I really want to see that project happen ^_^

Thanks Marc

Javier Gómez

unread,
Feb 12, 2013, 10:59:33 AM2/12/13
to joomla-...@googlegroups.com
Is there anyone available to test this pull request: https://github.com/joomla/joomla-cms/pull/707 and add comments?

Thanks ^_^

javier gómez

unread,
Feb 12, 2013, 12:01:51 PM2/12/13
to joomla-...@googlegroups.com
More info and updates here: http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=30040

^_^

--
You received this message because you are subscribed to the Google Groups "Joomla! CMS Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-cm...@googlegroups.com.

To post to this group, send an email to joomla-...@googlegroups.com.



--
Javi

Rob Clayburn

unread,
Feb 13, 2013, 4:52:02 AM2/13/13
to joomla-...@googlegroups.com
I just fixed an issue with it the new calendar in beez - the close and help buttons were not working.

I'd really like to see this tested before the next feature freeze. Its very simple to test honest and I think its visually quiet important to get included into the project

Chad Windnagle

unread,
Feb 13, 2013, 8:41:57 AM2/13/13
to joomla-...@googlegroups.com
I will test this in a bit. 


On Wednesday, February 13, 2013, Rob Clayburn wrote:
I just fixed an issue with it the new calendar in beez - the close and help buttons were not working.

I'd really like to see this tested before the next feature freeze. Its very simple to test honest and I think its visually quiet important to get included into the project

--
You received this message because you are subscribed to the Google Groups "Joomla! CMS Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-cm...@googlegroups.com.
To post to this group, send an email to joomla-...@googlegroups.com.
Visit this group at http://groups.google.com/group/joomla-dev-cms?hl=en-GB.
For more options, visit https://groups.google.com/groups/opt_out.
 
 


--



Small Logo
Chad Windnagle
s-go Consulting
607-330-2574 x103
607-229-6260 (Cell)
Website Design - SEO - Video

Follow Me: Facebook LinkedIn Twitter

Jerome G

unread,
Jun 5, 2013, 1:43:10 PM6/5/13
to joomla-...@googlegroups.com
Hi !

After several months, the Joomla 3.2 release is not so far and I want to see to finish an integration of a new date picker (using the JQuery Datepicker).
During the J&Beyond, I made a little "presentation" of the calendar and show how it is possible to override the rendering of the calendar (using a little extend) in order to have Hebreu/Farsi/Persian calendars.

We can find some implementation of this calendar in these languages, like here:
https://github.com/kbwood/calendars ( http://keith-wood.name/calendars.html )

Now we need some (Hebreu/Farsi/Persian ?) volunteers who can help us to check these calendars and explain us if something wrong so we will be able to fix it.

I think the JQuery date picker is really cool and provide a lot of new options.
It will propose new calendar displays, not only a single input with the calendar in popup.
I am convinced that it will be a good improvement of the user experience and users will be able to use it in the front end too.
If we can solve this languages problem, the rest of the implement will be fast and backward compatible.
Another new feature for Joomla 3.2 before the LTS release.

Best regards,
Jerome (HikaShop team - Obsidev)

Mohammad Hasani Eghtedar

unread,
Jun 24, 2013, 10:31:21 AM6/24/13
to joomla-...@googlegroups.com
Hi,
I added support of other calendars like jalali and arabic to jqueryui datepicker.
i think this is useful for this.
https://github.com/mhehm/jquery-ui/commit/3aede66e9c60d13de2089b0af911a2dd9bb20991
Reply all
Reply to author
Forward
0 new messages