Blog2010 ≫ Toothache has abated

Probably I bit into my gum, rather than an abcess

Thanks for the tips on how to deal with it, chewing foil, sucking a clove, or just going mediaeval on my own ass with a pair of pliers. The pain has dulled overnight, so I think I can safely leave it another fifteen years before I try the dentist.

Been having some grief with automated ical1 links at work, ie I put a link on the website you click it and it goes into your calendar, whatever your calendar may be (so long as your calendar supports ical1). I was getting a lot of This calendar file is unreadable. No events have been added to your iCal calendar, a general "something is not right" error. There are lots of examples out there, each one does it slightly differently so it was hard to track down where I was going wrong, in the end it turned out to be my header, I wanted just

header( 'Content-Type: text/calendar' );

instead of

header( 'Content-Type: text/x-vcalendar' );

that I got from the first example I saw... Here's a good working .ics file:

PRODID:-//My company//my product//EN
SUMMARY:[Hotel](/wiki/#hotel) (booking ref 6TQM3)

It can be very simple indeed, so all is good.

⬅️ :: ➡️

Paul Clarke's weblog - I live in Hythe near Folkestone. Wed + dad to two, I'm a full stack web engineer, + I do js / Node, some ruby, python, php etc. I like pubbing, parkrun, eating, home-automation and other diy jiggery-pokery, history, tree stuff, Television, squirrels, pirates, lego, and TIME TRAVEL.