Scheduler show UTC

Screenshot_5

Computer Time : 14:10

It currently shows the time relative to the computer clock. I want to do this as UTC +0 and make it look like the black drawing I showed. How can I do that?

Best regards.

Hello,

You can change the styles of the marker line, but the dhx_matrix_now_time CSS selector, as follows:

  .dhx_matrix_now_time {
    border-left: 5px solid black;
  }

Regarding this part:

You can do it by changing the now_date config:
https://docs.dhtmlx.com/scheduler/api__scheduler_now_date_config.html

by passing the UTC date into it, as follows:

var now = new Date();
var utc = new Date(now.getTime() + now.getTimezoneOffset() * 60000);
scheduler.config.now_date = new Date(utc);

Here is a demo:
http://snippet.dhtmlx.com/5/ffdf56b25

Best regards,

1 Like

Thanks for your help. It is working. :slight_smile: