diff options
-rw-r--r-- | README | 2 | ||||
-rw-r--r-- | admin.php | 3 | ||||
-rw-r--r-- | config.inc.php | 1 | ||||
-rw-r--r-- | day.php | 4 | ||||
-rw-r--r-- | functions/todo.js | 5 | ||||
-rw-r--r-- | month.php | 3 | ||||
-rw-r--r-- | preferences.php | 1 | ||||
-rw-r--r-- | print.php | 3 | ||||
-rw-r--r-- | search.php | 3 | ||||
-rw-r--r-- | templates/default/header.tpl | 17 | ||||
-rw-r--r-- | week.php | 3 | ||||
-rw-r--r-- | year.php | 3 |
12 files changed, 28 insertions, 20 deletions
@@ -96,6 +96,8 @@ Changes: -Support for 7 colors and 14 calendars by default. -Italian and Spanish translations added. -Some authentication issues resolved. + -Change your charset in config. + -Better Evolution compatibility. 2.0 alpha -New templating system. @@ -3,6 +3,7 @@ define('BASE', './'); require_once(BASE.'functions/admin_functions.php'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); // Redirect if administration is not allowed if ($allow_admin != "yes") { @@ -47,6 +48,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'template' => $template, 'cal' => $cal, diff --git a/config.inc.php b/config.inc.php index 4192d10..a53588a 100644 --- a/config.inc.php +++ b/config.inc.php @@ -26,6 +26,7 @@ $bleed_time = ''; // This allows events past midnight to just be displayed $cookie_uri = ''; // The HTTP URL to the PHP iCalendar directory, ie. http://www.example.com/phpicalendar -- AUTO SETTING -- Only set if you are having cookie issues. $download_uri = ''; // The HTTP URL to your calendars directory, ie. http://www.example.com/phpicalendar/calendars -- AUTO SETTING -- Only set if you are having subscribe issues. $default_path = 'http://www.example.com/phpicalendar'; // The HTTP URL to the PHP iCalendar directory, ie. http://www.example.com/phpicalendar +$charset = 'UTF-8'; // Character set your calendar is in, suggested UTF-8, or iso-8859-1 for most languages. // Yes/No questions --- 'yes' means Yes, anything else means no. 'yes' must be lowercase. $display_custom_goto = 'no'; // In the 'Jump To' box, display the custom 'go to day' box. @@ -12,6 +12,8 @@ $current_view = 'day'; require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/list_functions.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); + if ($minical_view == 'current') $minical_view = 'day'; $weekstart = 1; @@ -46,6 +48,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'template' => $template, 'cal' => $cal, diff --git a/functions/todo.js b/functions/todo.js index 3e71650..52cc96a 100644 --- a/functions/todo.js +++ b/functions/todo.js @@ -1,17 +1,12 @@ - <script language="JavaScript" type="text/javascript"> <!-- function openTodoInfo(vtodo_array) { var windowW = 460; var windowH = 275; - var url = "includes/todo.php?vtodo_array="+vtodo_array; - options = "scrollbars=yes,width="+windowW+",height="+windowH; - info = window.open(url, "Popup", options); - info.focus(); } @@ -3,6 +3,7 @@ define('BASE', './'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/list_functions.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); $current_view = "month"; if ($minical_view == 'current') $minical_view = 'month'; @@ -53,6 +54,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'calendar_nav' => BASE.'templates/'.$template.'/calendar_nav.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'template' => $template, 'cal' => $cal, 'getdate' => $getdate, diff --git a/preferences.php b/preferences.php index b8047b2..2b8574e 100644 --- a/preferences.php +++ b/preferences.php @@ -3,6 +3,7 @@ define('BASE','./'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); $display_date = $preferences_lang; if ($cookie_uri == '') { @@ -4,6 +4,7 @@ define('BASE', './'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/list_functions.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); $start_week_time = strtotime(dateOfWeek($getdate, $week_start_day)); $end_week_time = $start_week_time + (6 * 25 * 60 * 60); @@ -42,6 +43,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'template' => $template, 'cal' => $cal, @@ -6,6 +6,7 @@ $display_date = $results_lang; require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/list_functions.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); if (isset($HTTP_SERVER_VARS['HTTP_REFERER']) && $HTTP_SERVER_VARS['HTTP_REFERER'] != '') { $back_page = $HTTP_SERVER_VARS['HTTP_REFERER']; @@ -276,6 +277,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'template' => $template, 'cal' => $cal, diff --git a/templates/default/header.tpl b/templates/default/header.tpl index fa9c21c..df6723a 100644 --- a/templates/default/header.tpl +++ b/templates/default/header.tpl @@ -2,27 +2,14 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> - <meta http-equiv="content-type" content="text/html;charset=UTF-8" /> + <meta http-equiv="content-type" content="text/html; charset={CHARSET}" /> <title>{CALENDAR_NAME} - {DISPLAY_DATE}</title> <link rel="stylesheet" type="text/css" href="{DEFAULT_PATH}templates/{TEMPLATE}/default.css" /> <!-- switch rss_available on --> <link rel="alternate" type="application/rss+xml" title="RSS" href="{DEFAULT_VIEW}/rss/rss.php?cal={CAL}&rssview={CURRENT_VIEW}"> <!-- switch rss_available off --> {EVENT_JS} - <script language="JavaScript" type="text/javascript"> - <!-- - function openTodoInfo(vtodo_array) - { - var windowW = 460; - var windowH = 275; - var url = "includes/todo.php?vtodo_array="+vtodo_array; - options = "scrollbars=yes,width="+windowW+",height="+windowH; - info = window.open(url, "Popup", options); - info.focus(); - } - - //--> - </script> + {TODO_JS} </head> <body> <form name="eventPopupForm" id="eventPopupForm" method="post" action="includes/event.php" style="display: none;"> @@ -5,6 +5,7 @@ define('BASE', './'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/list_functions.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); if ($minical_view == "current") $minical_view = "week"; $starttime = "0500"; @@ -49,6 +50,8 @@ $page->replace_tags(array( 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'sidebar' => BASE.'templates/'.$template.'/sidebar.tpl', 'event_js' => BASE.'functions/event.js', + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'template' => $template, 'cal' => $cal, @@ -3,6 +3,7 @@ define('BASE', './'); require_once(BASE.'functions/ical_parser.php'); require_once(BASE.'functions/template.php'); +header("Content-Type: text/html; charset=$charset"); $current_view = 'year'; ereg ("([0-9]{4})([0-9]{2})([0-9]{2})", $getdate, $day_array2); @@ -20,6 +21,8 @@ $page->replace_tags(array( 'header' => BASE.'templates/'.$template.'/header.tpl', 'footer' => BASE.'templates/'.$template.'/footer.tpl', 'template' => $template, + 'todo_js' => BASE.'functions/todo.js', + 'charset' => $charset, 'default_path' => '', 'cal' => $cal, 'getdate' => $getdate, |