Ical VALARM未注册 [英] Ical VALARM not registrering

查看:302
本文介绍了Ical VALARM未注册的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用了最近几天来创建一个构建.ics文件(ical)的应用程序

I've used the last couple of days creating an application that constructs an .ics file (ical)

它是用php编码的, (时区,Vevent的,等等),但当我添加VALARM到那些VEVENT的既不是google日历,也不是Outlook 2010添加的日历的

It's coded in php, and the base functions work fine (timezones, Vevent's, and so on) but when i add VALARM's into those VEVENT's neither google calendar, nor Outlook 2010 add's the nofifications to their calendar's

的ics ics档案:

a snippet of the ics file:

BEGIN:VEVENT
UID:f2f5672145d92702c71504ceccf77167@dyndns.org
DTSTAMP:20120420T174122Z
DTSTART;TZID=Europe/Berlin:20120416T081000
DTEND;TZID=Europe/Berlin:20120416T091000
LOCATION:A102 - Teori Frh.
SUMMARY:Hold: 2.B Kemi B
DESCRIPTION:Lærer: Jeppe Byrialsen Jensen (JBJ) Noter: Lab øvelser om alkoholers blandbarhed
BEGIN:VALARM
ACTION:DISPLAY
DESCRIPTION:Hold: 2.B Kemi B
TRIGGER:-P0DT0H30M0S
END:VALARM
END:VEVENT

编辑:
如果你从文件中导入它似乎工作,但很遗憾,我需要从网站导入它。

It seems to work if you import it from a file, but sadly i need to import it from a website.

推荐答案

我们有同样的问题,但发现示例代码片段使用 \\\
每一行都需要使用 \r\\\

We had the same problem, but found that example code snippets which use \n at the end of each line need to use \r\n instead.

http://severinghaus.org/projects/icv/ 将此标记为警告,尽管iCal文件除了提醒

The iCal validator at http://severinghaus.org/projects/icv/ highlighted this as a warning, despite the iCal files working except for the reminder alarm not being set in Outlook 2010.

这里是一个示例iCal文件,它在Outlook 2010中打开时的工作原理,包括将提醒设置为1小时因为换行符 \r\\\
):

Here is an example iCal file which works exactly as expected when opened in Outlook 2010, including setting the reminder to 1 hour (as long as the line breaks are \r\n):

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Keeble Smith//NONSGML GETONCOURT.COM//EN
BEGIN:VEVENT
DTSTART:20130514T190000Z
DTEND:20130514T194000Z
LOCATION:Court 2\, Demo Squash Club
DESCRIPTION:View this court booking on getoncourt.com: http://democlub.getoncourt.com/booking-details/dmo3106
SUMMARY:Squash court booking for John Smith - DMO3106
BEGIN:VALARM
TRIGGER:-PT60M
ACTION:DISPLAY
DESCRIPTION:Reminder
END:VALARM
END:VEVENT
END:VCALENDAR

请注意转义的特殊字符。确保您在TEXT值(不是EOL实例)中转义以下内容:

Note also the escaped special characters. Ensure you escape the following in TEXT values (not the EOL instance though):

\  to  \\
;  to  \;
,  to  \,
\n to  \\n

这篇关于Ical VALARM未注册的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆