Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to format description text on calendar events for Android
    primarykey
    data
    text
    <p>I recently worked on a mobile website that generates calendar events, which when downloaded can be added to the device's native calendar. Out of the box, the ics format works great on outlook, and on iOS. However, Android is a bit trickier. Following the advice from this <a href="https://stackoverflow.com/questions/11825221/add-calendar-event-to-android-from-web-vcs-download">thread</a>, I served vCalendar (vcs) format to Android devices. </p> <p>This appears to be working great, aside from one thing - the descriptions. The <em>DESCRIPTION</em> element has text that spans multiple lines, but the line breaks don't appear to be escaping properly (as they do nicely in iOS). Instead when I serve the escaped line breaks, I'm getting them as literals within the <em>DESCRIPTION</em> text on the Android device, which just looks nasty.</p> <p>To clarify, this is how it looks on iOS:</p> <pre><code>This is the first sentence. This is the second sentence. </code></pre> <p>And on Android:</p> <pre><code>This is the first sentence.\nThis is the second sentence. </code></pre> <p>Not escaping the line breaks will of course mean that the DESCRIPTION ends once the first line breaks is encountered. Information on this whole topic is quite scarce, but has anyone got experience with how to deal with the line breaks on Android?</p> <p><strong>UPDATE</strong> I'm experiencing this issue on Samsung Galaxy S (GT-I9000) running Gingerbread (although it was the same on Eclair). Here's a screenshot after escaping \n to be \\n:</p> <p><a href="http://i48.tinypic.com/jb20jb.png" rel="nofollow noreferrer">http://i48.tinypic.com/jb20jb.png</a></p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload