diff options
author | Chad Little <clittle@users.sourceforge.net> | 2003-05-30 00:45:20 +0000 |
---|---|---|
committer | Chad Little <clittle@users.sourceforge.net> | 2003-05-30 00:45:20 +0000 |
commit | 544791f934e723c7393023a576f10ed6a21958ae (patch) | |
tree | 422b12af6e318dde1625edf08e180c1caa7c03d2 /functions | |
parent | 692c1adcc5bd52b8dc501ab2bffadf947d9b452b (diff) | |
download | phpicalendar-544791f934e723c7393023a576f10ed6a21958ae.tar.gz phpicalendar-544791f934e723c7393023a576f10ed6a21958ae.tar.bz2 phpicalendar-544791f934e723c7393023a576f10ed6a21958ae.zip |
Cleaned up look and feel of admin pages, corrected some error_reporting.
Diffstat (limited to 'functions')
-rw-r--r-- | functions/admin_functions.php | 14 | ||||
-rw-r--r-- | functions/ical_parser.php | 2 | ||||
-rw-r--r-- | functions/init.inc.php | 2 |
3 files changed, 9 insertions, 9 deletions
diff --git a/functions/admin_functions.php b/functions/admin_functions.php index 4bdd712..7e7a8a6 100644 --- a/functions/admin_functions.php +++ b/functions/admin_functions.php @@ -50,10 +50,10 @@ function login_ftp ($username, $password) { global $ftp_server; // set up basic connection - $conn_id = ftp_connect($ftp_server); + $conn_id = @ftp_connect($ftp_server); // login with username and password - $login_result = ftp_login($conn_id, $username, $password); + $login_result = @ftp_login($conn_id, $username, $password); // check connection if ((!$conn_id) || (!$login_result)) { @@ -61,7 +61,7 @@ function login_ftp ($username, $password) { } // close the FTP stream - ftp_close($conn_id); + @ftp_close($conn_id); return TRUE; } @@ -96,24 +96,24 @@ function delete_cal ($filename) { $filename = get_ftp_calendar_path() . "/" . $filename; // set up basic connection - $conn_id = ftp_connect($ftp_server); + $conn_id = @ftp_connect($ftp_server); // login with username and password - $login_result = ftp_login($conn_id, $HTTP_SESSION_VARS['phpical_username'], $HTTP_SESSION_VARS['phpical_password']); + $login_result = @ftp_login($conn_id, $HTTP_SESSION_VARS['phpical_username'], $HTTP_SESSION_VARS['phpical_password']); // check connection if ((!$conn_id) || (!$login_result)) return FALSE; // delete the file - $delete = ftp_delete($conn_id, $filename); + $delete = @ftp_delete($conn_id, $filename); // check delete status if (!$delete) return FALSE; // close the FTP stream - ftp_close($conn_id); + @ftp_close($conn_id); return TRUE; } diff --git a/functions/ical_parser.php b/functions/ical_parser.php index 05c9909..34dbebc 100644 --- a/functions/ical_parser.php +++ b/functions/ical_parser.php @@ -458,7 +458,7 @@ if ($parse_file) { if (!isset($bymonth)) $bymonth[] = date('m', $start_date_time); foreach($bymonth as $month) { $year = date('Y', $next_range_time); - if (is_array($byday)) { + if ((isset($byday)) && (is_array($byday))) { $checkdate_time = mktime(0,0,0,$month,1,$year); foreach($byday as $day) { ereg ('([-\+]{0,1})([0-9]{1})([A-Z]{2})', $day, $byday_arr); diff --git a/functions/init.inc.php b/functions/init.inc.php index 24df31d..1d8af84 100644 --- a/functions/init.inc.php +++ b/functions/init.inc.php @@ -6,7 +6,7 @@ //chmod(BASE.'calendars/School.ics',0666); // uncomment when developing, comment for shipping version -error_reporting (E_ALL); +//error_reporting (E_ALL); if (!defined('BASE')) define('BASE', './'); include(BASE.'config.inc.php'); |