[kronolith] How to serialize calendar entries in prefs.php

Rich Hutchinson rich at adastral.ucl.ac.uk
Thu Aug 9 14:47:59 UTC 2007


I'm looking to include some default user prefs inside
kronolith/config/prefs.php for the following options:

display_cals - to display selected calendars by default
fb_cals - to choose which calendars are used for free/busy info

For instance, say I had configured a shared calendar (or shared address
book) which has the id "abc123", I'd like it so that both this
calendar/address book and the user's own default calendar are
displayed/included in the preference.

I can't work out how to format the serialization, however. I know for
the calendar that it should be something like the form:

a:2:{i:0;s:9:"username";i:1;s:32:"abc123";}

How do you get the correct serialization for the first (user's default)
calendar? Obviously, the second one will always be in the form:
i:1;s:32:"abc123";

I've tried variations on "Auth::GetAuth()" in place of the username etc
but nothing seems to work - the "s" value is different for each user too...

Can anyone help?

Many thanks in advance!


More information about the kronolith mailing list