In private messaging I learn that there some people for whom the work-around-wrapper doesn't work and where google makes no request from my server.
I suppose that google does some kind of caching magic which helps it decide not to bother trying again.
A solution which has worked is to make use of the flexibility of the wrapper, for example, if your work-around wrapper was:
https://mail.liddicott.com/ldscalendar.php/987654321
and this is not working, then try:
https://mail.liddicott.com/ldscalendar. ... lendar.ics
You can make up any file name you like on the end, and it will still work.
Such tricks has made the wrapper work in cases where google has otherwise refused to make any requests from my server.
I note that the ics file obtained from the LDS servers is very sparse and doesn't even identify which internal LDS calendar an event came from. If this is improved in a later release then I will be able to add filtering to the wrapper-URL's so that perhaps it may be possible to have URL's like:
https://mail.liddicott.com/ldscalendar. ... lendar.ics
to recieve a subset of calendars on your phone - and of course you could have multiple subset URLs
Workaround to fix calendar sync problems
-
- New Member
- Posts: 30
- Joined: Sun May 09, 2010 9:21 pm
- Location: USA, AZ
I had the lds.org feed working with Google Calendar for a few months when it died on me for some reason. Today I had some time to hunt down the issue: EOL characters in the middle of an event's description.
a validator gave the error: "It appears that this line has not been 'folded' properly according to the iCalendar standard."
I've edited your code a bit samliddicott, removing any EOL chars in $field and $value and now its working great! My edits can be found here: http://1b4.it/labs/lds/calendar.php
Thank you so much for posting the code!! (And making it easy for me to do the same!
Code: Select all
BEGIN:VEVENT
DTSTAMP:20110320T181054Z
DTSTART:20110225T020000Z
DTEND:20110225T031500Z
SUMMARY:Ward Preparation Specialist Training @ Cullumber Primary Room
UID:6c031d6e6dd8cdab39ad2627ebc0b0ef
DESCRIPTION:7:00 PM Ward
Preparation
Specialist
Training @
Cullumber
Primary Room
END:VEVENT
I've edited your code a bit samliddicott, removing any EOL chars in $field and $value and now its working great! My edits can be found here: http://1b4.it/labs/lds/calendar.php
Thank you so much for posting the code!! (And making it easy for me to do the same!

-
- Member
- Posts: 77
- Joined: Wed May 20, 2009 9:48 am
- Location: England
Thanks for solving that. I'd pinned that down as a potential cause but was waiting feedback from a guy with the problems.n.oliver wrote:I had the lds.org feed working with Google Calendar for a few months when it died on me for some reason. Today I had some time to hunt down the issue: EOL characters in the middle of an event's description.
a validator gave the error: "It appears that this line has not been 'folded' properly according to the iCalendar standard."Code: Select all
BEGIN:VEVENT DTSTAMP:20110320T181054Z DTSTART:20110225T020000Z DTEND:20110225T031500Z SUMMARY:Ward Preparation Specialist Training @ Cullumber Primary Room UID:6c031d6e6dd8cdab39ad2627ebc0b0ef DESCRIPTION:7:00 PM Ward Preparation Specialist Training @ Cullumber Primary Room END:VEVENT
I've edited your code a bit samliddicott, removing any EOL chars in $field and $value and now its working great! My edits can be found here: http://1b4.it/labs/lds/calendar.php
Thank you so much for posting the code!! (And making it easy for me to do the same!
I'll update my code. I think I'll replace the carriage return with a literal \n which seems to be the official way to start a new line.
I haven't seen any lines that actually wrap with a newline and don't begin a field properly - have you actually seen any like this?
-
- Member
- Posts: 77
- Joined: Wed May 20, 2009 9:48 am
- Location: England
I added this line:
which replaces inline carriage returns with \n, so I hope that the wrapper is working for more people now.
I don't think any other of your changes were needed - from analyzing existing calendars there were no lines that began without an ICAL field name on the input.
Code: Select all
while (($p=strpos($line, "\r", $p)) && $p<(strlen($line)-2)) $line=substr_replace($line, "\\n", $p, 1);
I don't think any other of your changes were needed - from analyzing existing calendars there were no lines that began without an ICAL field name on the input.
-
- New Member
- Posts: 4
- Joined: Sun Mar 27, 2011 11:10 pm
-
- New Member
- Posts: 18
- Joined: Mon Mar 28, 2011 11:39 am
- Location: USA, Utah, Vernal
Workaround to fix calendar sync problems
Hummmm . . . I'm still having problems getting things to update on a google calendar from my lds.org calendar. I'm using samliddicott wrapper address and it did populate my calendar initially, but won't update with a delete I just tried from my lds.org calendar as a test.
I've also tried putting the fake file name on the end of the update URL, but I'm not sure I'm doing that correctly.
Thoughts?
-dc
I've also tried putting the fake file name on the end of the update URL, but I'm not sure I'm doing that correctly.
Thoughts?
-dc
-
- New Member
- Posts: 18
- Joined: Mon Mar 28, 2011 11:39 am
- Location: USA, Utah, Vernal
Workaround to fix calendar sync problems
I was able to get the fake file approach to work, but does this mean I will need to do this, using a different file name, each time I want to refresh my google calendar from lds.org?
-dc
-dc
-
- Member
- Posts: 77
- Joined: Wed May 20, 2009 9:48 am
- Location: England
I don't know. It seems like changing the fake filename is more needed when you remove/add the calendar URL to your googe calendar. The refreshing of the entries should happen automatically.drcook345 wrote:I was able to get the fake file approach to work, but does this mean I will need to do this, using a different file name, each time I want to refresh my google calendar from lds.org?
-
- New Member
- Posts: 18
- Joined: Mon Mar 28, 2011 11:39 am
- Location: USA, Utah, Vernal
Workaround to fix calendar sync problems
samliddicott, thanks for your help BTW . . . Yeah, for some reason my google calendar is not getting updates.
Has anyone else seen this problem and have any ideas on a solution?
-dc
Has anyone else seen this problem and have any ideas on a solution?
-dc
-
- New Member
- Posts: 18
- Joined: Mon Mar 28, 2011 11:39 am
- Location: USA, Utah, Vernal