pquery($delquery, array($_REQUEST["current_userid"])); $selectedid = $_REQUEST['shar_userid']; $sharedid = explode (";",$selectedid); if(isset($sharedid) && $sharedid != null) { foreach($sharedid as $sid) { if($sid != '') { $sql = "insert into vtiger_sharedcalendar values (?,?)"; $adb->pquery($sql, array($_REQUEST["current_userid"], $sid)); } } } if(isset($_REQUEST['start_hour']) && $_REQUEST['start_hour'] != '') { $sql = "update vtiger_users set start_hour=? where id=?"; $adb->pquery($sql, array($_REQUEST['start_hour'], $current_user->id)); } $sql = "update vtiger_users set hour_format=? where id=?"; $adb->pquery($sql, array($hour_format, $current_user->id)); RecalculateSharingRules(); header("Location: index.php?action=index&module=Calendar&view=".vtlib_purify($_REQUEST['view'])."&hour=".vtlib_purify($_REQUEST['hour'])."&day=".vtlib_purify($_REQUEST['day'])."&month=".vtlib_purify($_REQUEST['month'])."&year=".vtlib_purify($_REQUEST['year'])."&viewOption=".vtlib_purify($_REQUEST['viewOption'])."&subtab=".vtlib_purify($_REQUEST['subtab'])."&parenttab=".getParentTab()); ?>