• 0

Most basic calendar for integration with webapp


Question

I'm looking to build a web app purely for my own personal use.  What I want to do is:

  • Show a list of days
  • For each day have a drop-down of 3 options - only 0 or 1 can be selected
  • When selecting an option, store this data to database (date, option chosen)
  • When changing an option (even to the not-set state) store this data to database overriding what was set (date, option chosen)

All the above is simple.  However, here's the bit I don't get yet:

  • When selecting or changing an option - create a calendar event in either iCloud or Alexa calendar to represent the option chosen
  • If an event already exists on that date - delete it and then create a new one

I would prefer this to work with iCloud calendar, but I fear that there's little integration ability here with my chosen language (PHP).

Could I even just output the database content in a relevant format and subscribe to it from iCloud calendar?

Any steering would be useful.  Thanks

4 answers to this question

Recommended Posts

  • 0
  On 12/01/2024 at 19:41, Dick Montage said:

I'm looking to build a web app purely for my own personal use.  What I want to do is:

  • Show a list of days
  • For each day have a drop-down of 3 options - only 0 or 1 can be selected
  • When selecting an option, store this data to database (date, option chosen)
  • When changing an option (even to the not-set state) store this data to database overriding what was set (date, option chosen)

All the above is simple.  However, here's the bit I don't get yet:

  • When selecting or changing an option - create a calendar event in either iCloud or Alexa calendar to represent the option chosen
  • If an event already exists on that date - delete it and then create a new one

I would prefer this to work with iCloud calendar, but I fear that there's little integration ability here with my chosen language (PHP).

Could I even just output the database content in a relevant format and subscribe to it from iCloud calendar?

Any steering would be useful.  Thanks

Expand  

I was hopeful until I read PHP. Maybe something like this for icloud? https://github.com/zubini/php_icloud_calendar

Or alternatively this for Alexa skills: https://github.com/maxbeckers/amazon-alexa-php

----

I know you're probably not looking for alternate languages and I'm not sure how comfortable you are with Python, but a few years ago I started using Django for my web projects instead of PHP and I found it pretty easy to pick up. If you were to consider using that, you could use something like this: https://github.com/jazzband/django-ical or this: https://github.com/picklepete/pyicloud

I'm curious to see how you crest this hurdle so keep us posted!

----

Edit: I reread your post and saw this: "Could I even just output the database content in a relevant format and subscribe to it from iCloud calendar?"

I went to this website to see if I could generate an ics file using basic event information: https://ical.marudot.com/

This is the information I entered regarding the event itself:

image.png.95763628f775583823177a10a06896d4.png

This is the information I entered regarding the feed name:

image.png.fe232d50b0988e2afcfb808054914436.png

The following is the contents of the .ics file it generated:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//ical.marudot.com//iCal Event Maker
X-WR-CALNAME:Test Feed Title
NAME:Test Feed Title
REFRESH-INTERVAL;VALUE=DURATION:P1H
CALSCALE:GREGORIAN
BEGIN:VTIMEZONE
TZID:America/Havana
LAST-MODIFIED:20230407T050750Z
TZURL:https://www.tzurl.org/zoneinfo-outlook/America/Havana
X-LIC-LOCATION:America/Havana
BEGIN:STANDARD
TZNAME:CST
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
DTSTART:19701101T010000
RRULE:FREQ=YEARLY;BYMONTH=11;BYDAY=1SU
END:STANDARD
BEGIN:DAYLIGHT
TZNAME:CDT
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
DTSTART:19700308T000000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=2SU
END:DAYLIGHT
END:VTIMEZONE
BEGIN:VEVENT
DTSTAMP:20240112T204354Z
UID:1705092190603-72779@ical.marudot.com
DTSTART;TZID=America/Havana:20240112T100000
DTEND;TZID=America/Havana:20240112T120000
SUMMARY:Test Event Title
URL:https://test-url.example
DESCRIPTION:Test Description
LOCATION:Test Location
TRANSP:TRANSPARENT
X-MICROSOFT-CDO-BUSYSTATUS:TENTATIVE
CLASS:PUBLIC
END:VEVENT
END:VCALENDAR

If you could generate an ics file that looks like that, I think you're in business.

Edited by satukoro
  • 0
  On 13/01/2024 at 09:43, Laser said:

Have you looked at fullcalender? it is a robust full featured calendar that is under active dev.

Here is a sample of integrating it in php

PHP Event Calendar using FullCalendar JS Library - CodexWorld

Expand  

This looks interesting, thanks!  And while that's great - I can't subscribe to it from cloud calendars or so on.  Usefully interesting nonetheless though, thanks.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • they will use your data anyways, this way you at least get to take advantage of it, might as well use it
    • I think its a great thing, whoever messes with my msgs is going to be real bored. Even those who dont trust meta, like myself, if the gains translate into an improved communication, easiness, everyone will use it. The alternative is not use Meta Whatsapp since they will AI your msgs an resume it anyways
    • Write-Host “Initiate porno mode!” -ForegroundColor Red Read-Host “Press the any key to continue” Save as “PornoMode.ps1
    • The so called tri-fold phone is not a phone just like today's so called smartphones are not phones. They are computing camera devices with the ability to make and receive phone calls. For many the phone app is among the least used apps on these so called smartphones.
    • Backpack Hero and Figment are free to claim on the Epic Games Store by Pulasthi Ariyasinghe The Epic Games Store has just refreshed its weekly giveaways promotion, and there are two games up for grabs this time. Replacing the Sable freebie from last week, Backpack Hero and Figment have now landed for all PC gamers to claim. As always, you have seven days to add the latest indie game permanently to your Epic Games Store library. From the double giveaway, Backpack Hero comes in from indie developer Jaspel, offering a unique inventory management roguelike experience. Aside from collecting items to maximize the potential of a run, like with other roguelikes, here, your placement of the item in the backpack also matters. Each run offers randomly generated dungeons, enemies, and loot to grab. Next, Figment lands from Bedtime Digital Games. This isometric perspective action adventure game takes place in a surreal landscape with hand-drawn artwork, and everything is taking place inside a mind. You take the role of Dusty, the former voice of courage in the mind. The musical adventure involves trying to return Dusty to his old self while also helping the mind beat back its nightmares and restoring its original purpose. The Figment and Backpack Hero giveaways on the Epic Games Store are now active, and they will last until July 10. When not on sale, both games come in at $19.99 to purchase, but PC gamers can add the duo to their library for no cost during the seven-day timeframe. When the giveaways refresh next week, Epic Games plans on giving away two more games: the next musical adventure, Figment 2: Creed Valley, as well as the classic arcade-inspired shoot’em up Sky Racket.
  • Recent Achievements

    • Week One Done
      Devesh Beri earned a badge
      Week One Done
    • Week One Done
      956400 earned a badge
      Week One Done
    • First Post
      loose_observer earned a badge
      First Post
    • Week One Done
      BeeJay_Balu earned a badge
      Week One Done
    • Week One Done
      filminutz earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      454
    2. 2
      ATLien_0
      158
    3. 3
      +FloatingFatMan
      153
    4. 4
      Nick H.
      65
    5. 5
      +thexfile
      62
  • Tell a friend

    Love Neowin? Tell a friend!