1 --- ./misc/cli/eventum~ 2005-01-19 02:47:20.000000000 +0200
2 +++ ./misc/cli/eventum 2005-01-19 03:02:40.119100405 +0200
7 -require_once("config.inc.php");
8 +require_once("/etc/eventum/cli.php");
9 require_once(APP_INC_PATH . "class.command_line.php");
10 require_once(APP_PEAR_PATH . "XML_RPC/RPC.php");
12 --- eventum-1.4.orig/misc/cli/config.inc.php 2005-01-26 00:00:58.000000000 +0200
13 +++ eventum-1.4/misc/cli/config.inc.php 2005-01-25 23:57:39.000000000 +0200
17 // definitions of path related variables
18 -@define("APP_PATH", dirname(__FILE__) . '/');
19 +@define("APP_PATH", '/usr/share/eventum/cli/');
20 @define("APP_INC_PATH", APP_PATH . "include/");
21 @define("APP_PEAR_PATH", APP_INC_PATH . "pear/");
22 -if (stristr(PHP_OS, 'darwin')) {
23 - ini_set("include_path", ".:" . APP_PEAR_PATH);
24 -} elseif (stristr(PHP_OS, 'win')) {
25 - ini_set("include_path", ".;" . APP_PEAR_PATH);
27 - ini_set("include_path", ".:" . APP_PEAR_PATH);
29 +ini_set("include_path", ".:" . APP_PEAR_PATH);
31 @define("APP_BENCHMARK", false);
33 --- eventum-1.4/misc/cli/config.inc.php~ 2005-02-22 21:35:52.000000000 +0200
34 +++ eventum-1.4/misc/cli/config.inc.php 2005-02-22 21:44:10.000000000 +0200
37 // definitions of path related variables
38 @define("APP_PATH", '/usr/share/eventum/cli/');
39 -@define("APP_INC_PATH", APP_PATH . "include/");
40 +@define("APP_INC_PATH", APP_PATH);
41 @define("APP_PEAR_PATH", APP_INC_PATH . "pear/");
42 ini_set("include_path", ".:" . APP_PEAR_PATH);
44 @define("APP_BENCHMARK", false);
46 \ No newline at end of file
48 --- ./misc/cli/config.inc.php~ 2005-02-22 21:49:37.000000000 +0200
49 +++ ./misc/cli/config.inc.php 2005-02-22 21:50:01.000000000 +0200
51 // definitions of path related variables
52 @define("APP_PATH", '/usr/share/eventum/cli/');
53 @define("APP_INC_PATH", APP_PATH);
54 -@define("APP_PEAR_PATH", APP_INC_PATH . "pear/");
55 +@define("APP_PEAR_PATH", "/usr/share/pear/");
56 ini_set("include_path", ".:" . APP_PEAR_PATH);
58 @define("APP_BENCHMARK", false);
59 --- ./misc/cli/eventum~ 2005-01-24 17:49:25.000000000 +0200
60 +++ ./misc/cli/eventum 2005-01-25 15:48:56.000000000 +0200
63 require_once("/etc/webapps/eventum/cli.php");
64 require_once(APP_INC_PATH . "class.command_line.php");
65 -require_once(APP_PEAR_PATH . "XML_RPC/RPC.php");
66 +require_once(APP_PEAR_PATH . "XML/RPC.php");
68 list($user_email, $user_password, $url, $port, $relative_url) = Command_Line::getEnvironmentSettings();
70 --- ./misc/cli/include/class.command_line.php 2005-01-05 01:06:03.000000000 +0200
71 +++ ./misc/cli/include/class.command_line.php 2005-01-25 15:48:56.000000000 +0200
75 require_once(APP_INC_PATH . "class.misc.php");
76 -require_once(APP_PEAR_PATH . "XML_RPC/RPC.php");
77 +require_once(APP_PEAR_PATH . "XML/RPC.php");
79 $_displayed_confirmation = false;
81 --- eventum-localization-dev/include/class.template.php~ 2006-04-10 23:48:12.740151749 +0300
82 +++ eventum-localization-dev/include/class.template.php 2006-04-10 23:48:16.310231300 +0300
85 $this->smarty = new Smarty;
86 $this->smarty->template_dir = APP_TPL_PATH;
87 - $this->smarty->compile_dir = APP_PATH . "templates_c";
88 + $this->smarty->compile_dir = '/var/cache/eventum';
89 $this->smarty->config_dir = '';
90 $this->smarty->register_modifier("activateLinks", array('Link_Filter', 'activateLinks'));
91 $this->smarty->register_modifier("formatCustomValue", array('Custom_Field', 'formatValue'));
92 --- ./include/class.monitor.php~ 2005-02-22 21:50:49.000000000 +0200
93 +++ ./include/class.monitor.php 2005-02-22 23:04:50.000000000 +0200
98 + $required_directories = array();
99 foreach ($required_directories as $dir_path => $options) {
100 // check if directory exists
101 if (!file_exists($dir_path)) {
102 --- eventum-20060717/setup/index.php~ 2006-07-18 00:20:57.530267420 +0300
103 +++ eventum-20060717/setup/index.php 2006-07-18 00:22:06.301805247 +0300
104 @@ -121,31 +121,31 @@
105 if (ini_get('allow_call_time_pass_reference') != "1") {
106 $errors[] = "The 'allow_call_time_pass_reference' directive needs to be enabled in your PHP.INI file in order for Eventum to work properly.";
108 - $error = checkPermissions('../locks', "Directory 'locks'", TRUE);
109 + $error = checkPermissions('/var/run/eventum', "Directory '/var/run/eventum'", TRUE);
110 if (!empty($error)) {
113 - $error = checkPermissions('../logs', "Directory 'logs'", TRUE);
114 + $error = checkPermissions('/var/log/eventum', "Directory '/var/log/eventum'", TRUE);
115 if (!empty($error)) {
118 - $error = checkPermissions('../templates_c', "Directory 'templates_c'", TRUE);
119 + $error = checkPermissions('/var/cache/eventum', "Directory '/var/cache/eventum'", TRUE);
120 if (!empty($error)) {
123 - $error = checkPermissions('../config.inc.php', "File 'config.inc.php'");
124 + $error = checkPermissions('/etc/webapps/eventum/config.php', "File '/etc/webapps/eventum/config.php'");
125 if (!empty($error)) {
128 - $error = checkPermissions('../logs/errors.log', "File 'logs/errors.log'");
129 + $error = checkPermissions('/var/log/eventum/errors.log', "File '/var/log/eventum/errors.log'");
130 if (!empty($error)) {
133 - $error = checkPermissions('../setup.conf.php', "File 'setup.conf.php'");
134 + $error = checkPermissions('/etc/webapps/eventum/setup.php', "File '/etc/webapps/eventum/setup.php'");
135 if (!empty($error)) {
138 - $error = checkPermissions('../include/private_key.php', "File 'include/private_key.php'");
139 + $error = checkPermissions('/etc/webapps/eventum/private_key.php', "File '/etc/webapps/eventum/private_key.php'");
140 if (!empty($error)) {
143 --- eventum-20060918/setup/index.php~ 2006-09-19 00:15:15.216195060 +0300
144 +++ eventum-20060918/setup/index.php 2006-09-19 00:15:18.346265301 +0300
148 // check if config.inc.php in the root directory is writable
149 - if (!is_writable('../config.inc.php')) {
150 - return "The file 'config.inc.php' in Eventum's root directory needs to be writable by the web server user. Please correct this problem and try again.";
151 + if (!is_writable('/etc/webapps/eventum/config.php')) {
152 + return "The file '/etc/webapps/eventum/config.php' needs to be writable by the web server user. Please correct this problem and try again.";
154 // gotta check and see if the provided installation path really exists...
155 if (!file_exists($_POST['path'])) {
156 @@ -287,16 +287,16 @@
157 $private_key = '<?php
158 $private_key = "' . md5(microtime()) . '";
160 - if (!is_writable('../include/private_key.php')) {
161 - return "The file 'include/private_key.php' needs to be writable by the web server user. Please correct this problem and try again.";
162 + if (!is_writable('/etc/webapps/eventum/private_key.php')) {
163 + return "The file '/etc/webapps/eventum/private_key.php' needs to be writable by the web server user. Please correct this problem and try again.";
165 - $fp = @fopen('../include/private_key.php', 'w');
166 + $fp = @fopen('/etc/webapps/eventum/private_key.php', 'w');
168 - return "Could not open the file 'include/private_key.php' for writing. The permissions on the file should be set as to allow the user that the web server runs as to open it. Please correct this problem and try again.";
169 + return "Could not open the file '/etc/webapps/eventum/private_key.php' for writing. The permissions on the file should be set as to allow the user that the web server runs as to open it. Please correct this problem and try again.";
171 $res = fwrite($fp, $private_key);
173 - return "Could not write the configuration information to 'include/private_key.php'. The file should be writable by the user that the web server runs as. Please correct this problem and try again.";
174 + return "Could not write the configuration information to '/etc/webapps/eventum/private_key.php'. The file should be writable by the user that the web server runs as. Please correct this problem and try again.";
177 // check if we can connect
179 $tpl->assign('is_imap_enabled', function_exists('imap_open'));
183 -$full_url = dirname($_SERVER['PHP_SELF']);
184 -$pieces = explode("/", $full_url);
185 -$relative_url = array();
186 -$relative_url[] = '';
187 -foreach ($pieces as $piece) {
188 - if ((!empty($piece)) && ($piece != 'setup')) {
189 - $relative_url[] = $piece;
192 -$relative_url[] = '';
193 -$relative_url = implode("/", $relative_url);
194 +$relative_url = '/eventum/';
196 $tpl->assign("phpversion", phpversion());
197 $tpl->assign("rel_url", $relative_url);
198 --- ./index.php~ 2005-04-22 18:33:06.556398818 +0300
199 +++ ./index.php 2005-04-22 18:33:07.885180913 +0300
201 require_once(APP_INC_PATH . "db_access.php");
203 // check if templates_c is writable by the web server user
204 -if (!Misc::isWritableDirectory(APP_PATH . 'templates_c')) {
205 - $errors = array("Directory 'templates_c' is not writable.");
206 +if (!Misc::isWritableDirectory('/var/cache/eventum')) {
207 + $errors = array("Directory '/var/cache/eventum' is not writable.");
208 Misc::displayRequirementErrors($errors);
211 --- ../include/class.support.php~ 2005-07-10 15:40:57.000000000 +0300
212 +++ ../include/class.support.php 2005-07-14 22:47:58.665843734 +0300
215 function saveRoutedEmail($message)
217 - $path = APP_PATH . "misc/routed_emails/";
218 + $path = "/var/lib/eventum/routed_emails/";
219 list($usec,) = explode(" ", microtime());
220 $filename = date('dmY.His.') . $usec . '.email.txt';
221 $fp = @fopen($path . $filename, 'w');
222 --- eventum-20051221/include/class.draft.php~ 2005-12-21 17:56:27.000000000 +0200
223 +++ eventum-20051221/include/class.draft.php 2005-12-21 17:59:26.000000000 +0200
226 function saveRoutedMessage($message)
228 - $path = APP_PATH . "misc/routed_drafts/";
229 + $path = "/var/lib/eventum/routed_drafts/";
230 list($usec,) = explode(" ", microtime());
231 $filename = date('dmY.His.') . $usec . '.draft.txt';
232 $fp = @fopen($path . $filename, 'w');
233 --- eventum-20051221/include/class.note.php~ 2005-12-21 17:56:27.000000000 +0200
234 +++ eventum-20051221/include/class.note.php 2005-12-21 17:59:57.000000000 +0200
237 function saveRoutedNote($message)
239 - $path = APP_PATH . "misc/routed_notes/";
240 + $path = "/var/lib/eventum/routed_notes/";
241 list($usec,) = explode(" ", microtime());
242 $filename = date('dmY.His.') . $usec . '.note.txt';
243 $fp = @fopen($path . $filename, 'w');
244 --- ../setup/index.php~ 2005-07-26 18:49:37.000000000 +0300
245 +++ ../setup/index.php 2005-07-26 19:12:57.000000000 +0300
247 $config_contents = str_replace("%{APP_ENABLE_FULLTEXT}%", "false", $config_contents);
250 - $fp = @fopen('../config.inc.php', 'w');
251 + $fp = @fopen('/etc/webapps/eventum/config.php', 'w');
253 return "Could not open the file 'config.inc.php' for writing. The permissions on the file should be set as to allow the user that the web server runs as to open it. Please correct this problem and try again.";
255 --- eventum-localization-dev2/setup/index.php~ 2006-06-02 00:58:11.321514674 +0300
256 +++ eventum-localization-dev2/setup/index.php 2006-06-02 00:58:46.032294537 +0300
257 @@ -208,11 +208,11 @@
261 -require_once("../include/Smarty/Smarty.class.php");
262 +require_once("/usr/share/pear/Smarty/Smarty.class.php");
265 -$tpl->template_dir = '../templates/';
266 -$tpl->compile_dir = "../templates_c";
267 +$tpl->template_dir = '/usr/share/eventum/templates';
268 +$tpl->compile_dir = "/var/cache/eventum";
269 $tpl->config_dir = '';
271 function replace_table_prefix($str)
272 --- eventum-1.5.5/setup/index.php~ 2005-07-26 20:22:06.000000000 +0300
273 +++ eventum-1.5.5/setup/index.php 2005-07-26 20:35:31.000000000 +0300
278 -if (stristr(PHP_OS, 'darwin')) {
279 - ini_set("include_path", ".:./../include/pear/");
280 -} elseif (stristr(PHP_OS, 'win')) {
281 - ini_set("include_path", ".;./../include/pear/");
283 - ini_set("include_path", ".:./../include/pear/");
285 +ini_set("include_path", ".:../../include/pear/");
286 require_once("File/Util.php");
288 $html = checkRequirements();
289 --- eventum-localization-dev/include/class.template.php~ 2006-04-11 00:16:59.258616656 +0300
290 +++ eventum-localization-dev/include/class.template.php 2006-04-11 00:17:23.649160189 +0300
292 $this->smarty = new Smarty;
293 $this->smarty->template_dir = APP_TPL_PATH;
294 $this->smarty->compile_dir = '/var/cache/eventum';
295 + $this->smarty->plugins_dir = array('/usr/share/eventum/include/smarty', 'plugins');
296 $this->smarty->config_dir = '';
297 $this->smarty->register_modifier("activateLinks", array('Link_Filter', 'activateLinks'));
298 $this->smarty->register_modifier("formatCustomValue", array('Custom_Field', 'formatValue'));
299 --- ./include/class.misc.php 2005-10-26 17:17:17.000000000 +0300
300 +++ /tmp/class.misc.php 2005-10-26 17:30:12.000000000 +0300
303 function highlightQuotedReply($text)
305 - require_once(APP_SMARTY_PATH . "plugins/modifier.highlight_quoted.php");
306 + require_once(APP_INC_PATH. "smarty/modifier.highlight_quoted.php");
307 return smarty_modifier_highlight_quoted($text);