[kronolith] predefine remote-calendars - Some success

gimili gimili17 at gmail.com
Mon Mar 17 18:31:07 UTC 2014


On 3/17/14 12:45 PM, Jan Schneider wrote:
>
> Zitat von gimili <gimili17 at gmail.com>:
>
>> On 3/17/14 11:26 AM, Jan Schneider wrote:
>>>
>>> Zitat von gimili <gimili17 at gmail.com>:
>>>
>>>> n 11/09/11 8:52 AM, Jan Schneider wrote:
>>>>>
>>>>> Zitat von Makeri <makeri-kutsonu at t-online.de>:
>>>>>
>>>>>> Hello !
>>>>>>
>>>>>> We have multiple (Remote)-Calendars
>>>>>>
>>>>>> How can i (as Administrator) predefine the Calenders, so each 
>>>>>> user dont must add
>>>>>> remote-calendars self.
>>>>>
>>>>> They are stored in preferences, so you can set them like any other 
>>>>> preference.
>>>>>
>>>>> Jan.
>>>>>
>>>>
>>>> I couldn't get this to work.  I successfully subscribed to the 
>>>> remote calendar with one user then copied the settings into 
>>>> prefs.local.php but they do not show as default for other users.  
>>>> This calendar does not require authentication.  I tried it with and 
>>>> without the locked value. Any tips/advice appreciated?
>>>>
>>>> // remote calendars
>>>> $_prefs['remote_cals'] = array(
>>>>    'locked' => true,
>>>>    'value' => 
>>>> 'a:1:{i:0;a:6:{s:4:""name"";s:3:""HOL"";s:4:""desc"";s:0:"""";s:3:""url"";s:63:""https://mozorg.cdn.mozilla.net/media/caldata/EnglishHolidays.ics"";s:5:""color"";s:7:""#ef8dd8"";s:4:""user"";s:0:"""";s:8:""password"";s:0:"""";}}'
>>>> );
>>>>
>>>> // store the remote calendars to display
>>>> $_prefs['display_remote_cals'] = array(
>>>>    'locked' => true,
>>>>    'value' => 
>>>> 'a:1:{i:0;s:63:""https://mozorg.cdn.mozilla.net/media/caldata/EnglishHolidays.ics"";}'
>>>> );
>>>>
>>>> -- 
>>>> gimili
>>>
>>> Those are valid serialized PHP values.
>>
>> So are you saying it looks like I am doing it properly?  Thanks,
>>
>> -- 
>> gimili
>
> Ehm, no, that was a dumb typo. I meant those are NOT valid.

No problem.  You got me pointed in the right direction.

Some success.  I got the remote_cals to work with:
       'value' => 
'a:1:{i:0;a:3:{s:4:"name";s:17:"Holidays";s:3:"url";s:63:"https://mozorg.cdn.mozilla.net/media/caldata/EnglishHolidays.ics";s:5:"color";s:7:"#ef8dd8";}}'

I am now just trying to get it ticked on by default for new users but 
having no luck.

$_prefs['display_remote_cals'] = array(
       'value' => 
'a:1:{i:0;s:63:"https://mozorg.cdn.mozilla.net/media/caldata/EnglishHolidays.ics";}'

-- 
gimili



More information about the kronolith mailing list