Add line break in description field of yahoo calendar api

被刻印的时光 ゝ 提交于 2019-12-25 02:19:20

问题


I am trying to add a link to yahoo calendar events like this

https://calendar.yahoo.com/?v=60&DESC=Client%20Info%3A<br>Name%3A%20Hello%20World<br>&ST=20180630T070000&DUR=0100

But event description is appearing in same line. Other things are alright. Can anyone suggest how can I add line breaks in DESC so that it looks like this

Client Info
Name: Hello World

PS: Same description works fine in google calendar api.


回答1:


To break a line use %0d%0a (encoded CRLF or \r\n) or %0a (encoded LF or \n).

Example:

https://calendar.yahoo.com/?v=60&st=st20201231T193000&DUR=0200&desc=With%20clowns%0aand%20stuff&in_loc=North%20Pole

For more details you can check this document: https://github.com/InteractionDesignFoundation/add-event-to-calendar-docs/blob/master/services/yahoo.md



来源:https://stackoverflow.com/questions/50998928/add-line-break-in-description-field-of-yahoo-calendar-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!