1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
|
<?php /** * @version $Id: index.php,v 1.5 2005/01/23 03:24:16 kochp Exp $ * @package Mambo * @copyright (C) 2000 - 2005 Miro International Pty Ltd * @license http://www.gnu.org/copyleft/gpl.html GNU/GPL * Mambo is Free Software */
if (file_exists( "../configuration.php" ) && filesize( "../configuration.php" ) > 10) { header( "Location: ../index.php" ); exit(); } require_once ("../includes/version.php");
/** Include common.php */ include_once( "common.php" );
function get_php_setting($val) { $r = (ini_get($val) == '1' ? 1 : 0); return $r ? 'ON' : 'OFF'; }
function writableCell( $folder ) { echo '<tr>'; echo '<td class="item">' . $folder . '/</td>'; echo '<td align="left">'; echo is_writable( "../$folder" ) ? '<b><font color="green">Writeable</font></b>' : '<b><font color="red">Unwriteable</font></b>' . '</td>'; echo '</tr>'; }
echo "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?".">"; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Mambo - Web Installer</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <link rel="shortcut icon" href="../../images/favicon.ico" /> <link rel="stylesheet" href="install.css" type="text/css" /> <script type="text/javascript"> <!-- var checkobj function agreesubmit(el){ checkobj=el if (document.all||document.getElementById){ for (i=0;i<checkobj.form.length;i++){ //hunt down submit button var tempobj=checkobj.form.elements[i] if(tempobj.type.toLowerCase()=="submit") tempobj.disabled=!checkobj.checked } } }
function defaultagree(el){ if (!document.all&&!document.getElementById){ if (window.checkobj&&checkobj.checked) return true else{ alert("Please read/accept license to continue installation") return false } } } //--> </script> </head> <body>
<div id="wrapper"> <div id="header"> <div id="mambo"><img src="header_install.png" alt="Mambo Installation" /></div> </div> </div>
<div id="ctr" align="center"> <div class="install"> <div id="stepbar"> <div class="step-on">pre-installation check</div> <div class="step-off">license</div> <div class="step-off">step 1</div> <div class="step-off">step 2</div> <div class="step-off">step 3</div> <div class="step-off">step 4</div> </div>
<div id="right">
<div id="step">pre-installation check</div>
<div class="far-right"> <input name="Button2" type="submit" class="button" value="Next >>" onclick="window.location='install.php';" /> </div> <div class="clr"></div>
<h1>Pre-installation check for <?php echo $version; ?>:</h1> <div class="install-text"> If any of these items are highlighted in red then please take actions to correct them. Failure to do so could lead to your Mambo installation not functioning correctly. <div class="ctr"></div> </div>
<div class="install-form"> <div class="form-block">
<table class="content"> <tr> <td class="item"> PHP version >= 4.1.0 </td> <td align="left"> <?php echo phpversion() < '4.1' ? '<b><font color="red">No</font></b>' : '<b><font color="green">Yes</font></b>';?> </td> </tr> <tr> <td> - zlib compression support </td> <td align="left"> <?php echo extension_loaded('zlib') ? '<b><font color="green">Available</font></b>' : '<b><font color="red">Unavailable</font></b>';?> </td> </tr> <tr> <td> - XML support </td> <td align="left"> <?php echo extension_loaded('xml') ? '<b><font color="green">Available</font></b>' : '<b><font color="red">Unavailable</font></b>';?> </td> </tr> <tr> <td> - MySQL support </td> <td align="left"> <?php echo function_exists( 'mysql_connect' ) ? '<b><font color="green">Available</font></b>' : '<b><font color="red">Unavailable</font></b>';?> </td> </tr> <tr> <td valign="top" class="item"> configuration.php </td> <td align="left"> <?php if (@file_exists('../configuration.php') && @is_writable( '../configuration.php' )){ echo '<b><font color="green">Writeable</font></b>'; } else if (is_writable( '..' )) { echo '<b><font color="green">Writeable</font></b>'; } else { echo '<b><font color="red">Unwriteable</font></b><br /><span class="small">You can still continue the install as the configuration will be displayed at the end, just copy & paste this and upload.</span>'; } ?> </td> </tr> <tr> <td class="item"> Session save path </td> <td align="left"> <b><?php echo (($sp=ini_get('session.save_path'))?$sp:'Not set'); ?></b>, <?php echo is_writable( $sp ) ? '<b><font color="green">Writeable</font></b>' : '<b><font color="red">Unwriteable</font></b>';?> </td> </tr> </table> </div> </div> <div class="clr"></div>
<h1>Recommended settings:</h1> <div class="install-text"> These settings are recommended for PHP in order to ensure full compatibility with Mambo. <br /> However, Mambo will still operate if your settings do not quite match the recommended <div class="ctr"></div> </div>
<div class="install-form"> <div class="form-block">
<table class="content"> <tr> <td class="toggle"> Directive </td> <td class="toggle"> Recommended </td> <td class="toggle"> Actual </td> </tr> <?php $php_recommended_settings = array(array ('Safe Mode','safe_mode','OFF'), array ('Display Errors','display_errors','ON'), array ('File Uploads','file_uploads','ON'), array ('Magic Quotes GPC','magic_quotes_gpc','ON'), array ('Magic Quotes Runtime','magic_quotes_runtime','OFF'), array ('Register Globals','register_globals','OFF'), array ('Output Buffering','output_buffering','OFF'), array ('Session auto start','session.auto_start','OFF'), );
foreach ($php_recommended_settings as $phprec) { ?> <tr> <td class="item"><?php echo $phprec[0]; ?>:</td> <td class="toggle"><?php echo $phprec[2]; ?>:</td> <td> <?php if ( get_php_setting($phprec[1]) == $phprec[2] ) { ?> <font color="green"><b> <?php } else { ?> <font color="red"><b> <?php } echo get_php_setting($phprec[1]); ?> </b></font> <td> </tr> <?php } ?> </table> </div> </div> <div class="clr"></div>
<h1>Directory and File Permissions:</h1> <div class="install-text"> In order for Mambo to function correctly it needs to be able to access or write to certain files or directories. If you see "Unwriteable" you need to change the permissions on the file or directory to allow Mambo to write to it. <div class="clr"> </div> <div class="ctr"></div> </div>
<div class="install-form"> <div class="form-block">
<table class="content"> <?php writableCell( 'administrator/backups' ); writableCell( 'administrator/components' ); writableCell( 'administrator/modules' ); writableCell( 'administrator/templates' ); writableCell( 'cache' ); writableCell( 'components' ); writableCell( 'images' ); writableCell( 'images/banners' ); writableCell( 'images/stories' ); writableCell( 'language' ); writableCell( 'mambots' ); writableCell( 'mambots/content' ); writableCell( 'mambots/search' ); writableCell( 'media' ); writableCell( 'modules' ); writableCell( 'templates' ); ?> </table> </div> <div class="clr"></div> </div> <div class="clr"></div> </div> <div class="clr"></div> </div> </div>
<div class="ctr"> Miro International Pty Ltd. © 2000 - 2004 All rights reserved.<br /> <a href="http://www.mamboserver.com" target="_blank">Mambo</a> is Free Software released under the GNU/GPL License. </div>
</body> </html>
|