【问题标题】:How can you set a timezone in an outlook.com link?如何在 outlook.com 链接中设置时区?
【发布时间】:2017-04-28 18:33:49
【问题描述】:

我正在尝试为英国的 Outlook 事件设置正确的时间,但 Outlook 似乎为 BST(英国夏令时)设置了错误的时间。

这是一个链接,它创建了 2017 年 6 月 19 日下午 1254 到 1257 的活动。

在我的 Outlook 中,它会提前一个小时打开,即下午 1354。有没有办法在链接中明确设置时区?

我已尝试检查我的设置并使用其他 Outlook 帐户,因此我认为这不是我的邮件/日历设置的问题。

https://bay02.calendar.live.com/calendar/calendar.aspx?rru=addevent&dtstart=20170619T125400&dtend=20170619T125700&summary=Summary+of+the+event&location=Location+of+the+event&description=example+text.&allday=false&uid=

【问题讨论】:

    标签: email outlook calendar outlook.com outlook-calendar


    【解决方案1】:

    经过深入研究后,我意识到 Outlook 在发送链接时始终以 UTC 时间表示。因此,您需要将日期/时间从 BST 转换为 UTC。你可以像这样使用 PHP:

    $date = new DateTime('2017-06-22T12:54', new 
    DateTimeZone('Europe/London')); /* <-- Time zone to be converted */
    
    echo $date->format('YmdHis') . "\n";$date->setTimezone(new 
    DateTimeZone('UTC'));echo $date->format('YmdHis') . "\n"; /* <-- New time zone, UTC */
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-03-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-11-21
      • 2015-06-01
      相关资源
      最近更新 更多