Closed odin568 closed 1 year ago
Hi @djbrown
that was quick. Unfortunately it does not work directly as expected.
First the link generated uses the team name instead of the server url. So I get
<a href="MYTEAM/game/view?id=123">MYTEAM/game/view?id=123</a>
The problem is that the description field itself is from the rfc specs plain text, no html. So my mobile calendar app (aCalendar+) displays it as plain text. Perhaps it would interprete a full plaintext uri as clickable link - I don't know. So far I see the URI parameter and X-Properties. Unfortunately it is hard to say which is the "right" one in sense of compatibility. Would need to try it out probably.
Found some hints here: https://stackoverflow.com/a/67844673/3114804
Perhaps this is possible then:
DESCRIPTION;ALTREP="https://server-url.de/game/view?id=123":Open in SpielerPlus
At least for acalendar+, just adding the Link into newline as plaintext makes a clickable link Screenshot_20230613-192330.png
Thanks for pointing out the bug with the wrong URL. I mixed up the parameter order. Fixed that in 1d53e92.
As for the ICS formatting, I didn't read the specs 😬.
Instead I just created a test event on my Google Calendar, added formatted description and looked at the exported ics data.
It was just simple HTML, so I thought that was the standard.
But under 3.8.1.5. Description of the spec it states that the value type for DESCRIPTION
is just TEXT
. Google Calendar renders plain text URLs too, so I removed the HTML format from the description (<a>
and <br />
) in 0c4a7e0.
Also I thought about populating the URL
Property, but as far as I can tell Google Calendar (and probably most clients) don't use this property.
Found some hints here: https://stackoverflow.com/a/67844673/3114804
Perhaps this is possible then:
DESCRIPTION;ALTREP="https://server-url.de/game/view?id=123":Open in SpielerPlus
I also saw this in the spec, but decided against this because as I understand it, with the ALTREP
Property the whole description would be a link.
Thanks a lot - this now works! Yeah all clients do things differently potentially.
This now works perfectly for me. From the description in calendar, I can directly open the App itself as those links are registered to be opened by the App.
Hi, so far everything works fine. Some things I noticed: Using the endpoints, only the title is available as the event view returns it. This thereby does not contain i.e. "Heimspiel", etc. in our use case - but I could live with that - otherwise app would need to open each event propably, right?
But I saw you have the direct url to the event in the properties but dont write this into the ICS file. Would this be possible somehow as a html value? Not sure which key is necessary for this to work properly. Do you have any experience?
Benefit would be that it's then easy to get to details of the event itself right out of the calendar :-)
Thanks for your efforts so far - works like a charm