7 votes
Accepted

Calendar Field Showing Incorrect Date

When no filter is specified for a calendar field, the system will automatically apply the 'user_utc' filter. According to Joomla!'s documentation, this filter, "calculates the specified value to the ...
3 votes

Calendar Field Type

I would guess there's an implicit timezone conversion happening. It's saving the time as midnight GMT in the DB, but on re-display, it's converting it to local time.
2 votes

How to trigger javascript on a date selection on JHTML::_calendar

This is supported directly in core Joomla, at lease in version 3.8.5. JHTML::calendar takes five parameters, the value (date time), element name, element id, date time format and attributes. The ...
  • 492
2 votes

Joomla calendar popup does not appear when loaded by ajax

Your model successfully returns the HTML produced by the JHtml class call. But that method also loads some JavaScript code into the document head. Since you don't render the full page, that JavaScript ...
  • 5,537
2 votes
Accepted

Calendar Field render error "Double timezone specification"

My suggestion would be, simply change the database field to varchar or text for saving this form field and then the error should be gone. Then you can get back the string format date values from the ...
  • 2,436
2 votes

Populate Joomla Calendar field by jQuery not working

I noticed a change in the calendar widget in Joomla 3.8. In addition to the setting the value via val(), I also had to set the data-alt-value attribute as well. Otherwise it would fail validation. So, ...
1 vote

set server time as default at the calendar

why would someone has a totaly wrong date on his system?! but to answer your question: have you tried to set the filter to server_utc? from the docs: filter (optional) is time zone to be used. There ...
  • 483
1 vote
Accepted

Joomla Calendar format not displaying the correct format

Let's try this: Drop the format line completely from the xml definition. In its place try: translateformat="true" showtime="true" and see what that gives you. My guess here is the system is ...
  • 802
1 vote
Accepted

Add a Calendar field in Joomla 3.9 without using form xml

After testing this issue few times, you can realize that via the ajax call the Calendar HTML fields are created but it will not trigger the JoomlaCalendar javascript methods which are needed to create ...
  • 2,436
1 vote
Accepted

JS : How to trigger a Blur event with my code

Sometimes you can't see the forest for the trees. My JS now looks like this function addDate(target_field) { document.getElementById(target_field).value = currentDate(); document....
  • 2,375
1 vote
Accepted

Get value for joomla calendar input box to use in ajax call

Here's the glaring issue that I can detect via Google Chrome's developer tools... You have multiple instances of the element id (one nested inside another) that you are attempting to access. id ...
  • 4,493
1 vote

How to change date format in JHTML::calendar to d-m-Y?

The basic issue is that sql datetime field format is this: 'YYYY-MM-DD HH:MM:SS'. You can only save a date in this format when you save a date/time value (in MySQL at least). If you have a calendar ...
  • 2,436
1 vote
Accepted

Make calendar dynamically in 3.7

After digging around, I finally found the answer or at least got it to work. Not sure if there is a better way. First off, originally I was initializing from the input field. We now have to do it ...
  • 173
1 vote

Populate Joomla Calendar field by jQuery not working

I've found a way to do what you're looking for, but its a bit hacky! When you call JHtml::_( 'calendar', . . Joomla renders a div with the class 'field-calendar' into your document, and adds media/...
  • 492
1 vote

How to trigger javascript on a date selection on JHTML::_calendar

You can achive this behavior with a workaround (testing clicks on popup calendar days): jQuery(".icon-calendar").click(function(){ jQuery("body").on("click",".daysrow",function(){ /* Check ...
  • 967
1 vote

Joomla calendar popup does not appear when loaded by ajax

Bakual's answer actually should be accepted, but I just want to show the example of JS code that should be added to the page: <script> jQuery(document).ready(function($) { Calendar....
  • 4,055

Only top scored, non community-wiki answers of a minimum length are eligible