/**
* @throws Kronolith_Exception
*/
public function execute()
{
switch ($this->_vars->submitbutton) {
case _("Save"):
$info = array();
foreach (array('name', 'new_url', 'user', 'password', 'color', 'desc') as $key) {
$info[$key == 'new_url' ? 'url' : $key] = $this->_vars->get($key);
}
Kronolith::subscribeRemoteCalendar($info, trim($this->_vars->get('url')));
break;
case _("Unsubscribe"):
Horde::url('calendars/remote_unsubscribe.php')->add('url', $this->_vars->url)->redirect();
break;
case _("Cancel"):
Horde::url($GLOBALS['prefs']->getValue('defaultview') . '.php', true)->redirect();
break;
}
}