dependencies.tpl
7.8 KB
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
<!--<form id="license_dependencies_configuration" action="index.php?step_name=<?php //echo $step_name; ?>" method="post">-->
<form id="installtype_dependencies_configuration" action="index.php?step_name=<?php echo $step_name; ?>" method="post">
<p class="title">Checking PHP Dependencies</p>
<p class="description">
The wizard will review your system to determine whether you have the right PHP components in place to run KnowledgeTree. <!--<br/> -->
Once the scan is completed, you’ll see whether your system has met the requirements or whether there are areas you need to address.
</p>
<!--Continue Message-->
<?php
if(!$errors && $warnings) {
?>
<span class='big_ok'> </span>
<span class='description'>Congratulations! Your system is ready to run KnowledgeTree. Click <b>Next</b> to continue.</span>
<br/>
<!-- <br/>-->
<?php
}
?>
<!--Warning and Error Messages-->
<?php if($errors) { ?>
<span class='cross'> </span>
<span class='error_message'>Your system is not quite ready to run KnowledgeTree. See the list below to determine which areas you need to address. </span>
<?php } elseif ($warnings) { ?>
<span class='cross_orange'> </span>
<span class='warning_message'>Not all optional dependencies required by KnowledgeTree have been met but you will be able to continue.</span>
<?php } ?>
<?php
if($errors || $warnings) {
?>
<a href="http://wiki.knowledgetree.com/Web_Based_Installer#PHP_Dependencies" target="_blank" class="description_click">Click here for help on overcoming dependency issues</span></a>
<?php } ?>
<!--Content-->
<div id="step_content_<?php echo $step_name; ?>" class="step">
<?php
$iconFlag = "<span class='{$php}'> </span>";
$checkHeading = "<h3 style='width:30%; float:left'>".$iconFlag."PHP Version Check</h3>";
?>
<!-- PHP Version Check</h3>-->
<?php if($silent) { ?>
<?php if($versionSection) {
$details = 'Hide Details';
$display = 'block';
} else {
$details = 'Show Details';
$display = 'none';
}
?>
<?php
$phpVersionCheck = $checkHeading;
$phpVersionCheck .= "<div id='option1' class='onclick' onclick='javascript:{w.toggleClass(\"php_details\", \"option1\");}'>";
$phpVersionCheck .= $details."</div>";
$phpVersionCheck .= "<div class='php_details dependency_details' style='display:".$display.";'>";
?>
<?php } ?>
<?php
$space = "<p class='space'> </p>";
$phpVersionCheck .= "<p class='description dependencies'>Your version of PHP must be between 5.0 and 5.2 to run optimally. Versions that are 5.3 or higher are not recommended.</p>";
?>
<?php $phpVersionCheck .= "<span class='{$version['class']}'> </span>{$version['version']}"; ?>
<?php //echo "<span class='{$version['class']}'> </span>{$version['version']}"; ?>
<?php if($version['class'] != 'tick') { ?>
<?php if (AJAX) { ?>
<?php $phpVersionCheck .= "<a href='#' class='refresh' onclick='w.refresh('dependencies')'>Refresh</a>"; ?>
<?php } else { ?>
<?php $phpVersionCheck .= "<a href='javascript:this.location.reload();' class='refresh'>Refresh</a>"; ?>
<?php } ?>
<?php } ?>
<?php if($silent) { ?>
<?php $phpVersionCheck .= "</div>"; ?>
<?php } ?>
<?php echo $phpVersionCheck; ?>
<br />
<?php
$iconFlag = "<span class='{$php_ext}'> </span>";
$checkHeading = "<h3 style='width:30%; float:left'>".$iconFlag."PHP Extensions</h3>";
?>
<?php
if($silent) { ?>
<?php if($extensionSection) {
$details = 'Hide Details';
$display = 'block';
} else {
$details = 'Show Details';
$display = 'none';
}
?>
<?php
$phpExtensionCheck = $checkHeading;
$phpExtensionCheck .= "<div id='option2' class='onclick' onclick='javascript:{w.toggleClass(\"php_ext_details\", \"option2\");}'>";
$phpExtensionCheck .= $details."</div>";
$phpExtensionCheck .= "<div class='php_ext_details dependency_details' style='display:".$display.";'>";
?>
<?php } ?>
<?php
$phpExtensionCheck .= "<p class='description dependencies'>The extensions shown in red below are required for KnowledgeTree to run optimally. Items shown in orange are optional, but recommended.</p>";
?>
<br/>
<?php echo $phpExtensionCheck; ?>
<table class="description">
<?php
foreach($extensions as $ext) {
?>
<tr>
<?php
switch($ext['available']){
case 'yes':
$class = 'tick';
break;
case 'optional':
$class = 'cross_orange';
break;
case 'no':
default:
$class = 'cross';
}
?>
<td class="ext_indicator"><div class='<?php echo $class; ?>'></div></td>
<td class="ext_name"><?php echo $ext['name']; ?></td>
<?php echo ($ext['available'] != 'yes') ? "<td class='ext_description'>{$ext['details']}</td>" : '<td></td>'; ?>
<?php echo isset($errors[$ext['extension']]) ? "<td class='ext_error'><span class='error'>{$errors[$ext['extension']]}</span></td>" : '<td></td>'; ?>
<?php
if ($class == 'orange' || $class == 'cross') {
?>
<td class="ext_refresh">
<?php if (AJAX) { ?>
<a href="#" class="refresh" onclick="w.refresh('dependencies')">Refresh</a>
<?php } else { ?>
<a href="javascript:this.location.reload();" class="refresh">Refresh</a>
<?php } ?>
</td>
<?php
}
?>
<?php
}
?>
</table>
<?php if($silent) { ?>
</div>
<?php } ?>
<br />
<?php
$iconFlag = "<span class='{$php_con}'> </span>";
$checkHeading = "<h3 style='width:30%; float:left'>".$iconFlag."PHP Configurations</h3>";
?>
<?php
if($silent) { ?>
<?php if($configurationSection) {
$details = 'Hide Details';
$display = 'block';
} else {
$details = 'Show Details';
$display = 'none';
}
?>
<?php
$phpDirectivesCheck = $checkHeading;
$phpDirectivesCheck .= "<div id='option3' class='onclick' onclick='javascript:{w.toggleClass(\"php_con_details\", \"option3\");}'>";
$phpDirectivesCheck .= $details."</div>";
$phpDirectivesCheck .= "<div class='php_con_details dependency_details' style='display:".$display.";'>";
?>
<?php } ?>
<?php
$phpDirectivesCheck .= "<p class='description dependencies'>The configurations shown in red below are required for KnowledgeTree to run optimally. Items shown in orange are optional, but recommended.</p>";
?>
<br/>
<?php echo $phpDirectivesCheck; ?>
<table class="description">
<tr>
<th>Setting</th>
<th>Recommended value</th>
<th>Current value</th>
</tr>
<?php
foreach($configurations as $config) {
?>
<tr>
<td class="dir_name"><?php echo $config['name']; ?></td>
<td class="dir_description"><?php echo $config['recommended']; ?></td>
<td class="<?php echo $config['class']; ?>"><?php echo $config['setting']; ?></td>
<?php
if ($config['class'] == 'orange' || $config['class'] == 'cross') {
?>
<td class="ext_refresh">
<?php if (AJAX) { ?>
<a href="#" class="refresh" onclick="w.refresh('dependencies')">Refresh</a>
<?php } else { ?>
<a href="javascript:this.location.reload();" class="refresh">Refresh</a>
<?php } ?>
</td>
<?php
}
?>
</tr>
<?php
}
?>
</table>
<br/>
B = Bytes, K = Kilobytes, M = Megabytes, G = Gigabytes
<?php if($silent) { ?>
</div>
<?php } ?>
</div>
<input type="submit" name="Previous" value="Previous" class="button_previous"/>
<input type="submit" name="Next" value="Next" class="button_next"/>
</form>
<?php if (AJAX) { echo $html->js('form.js'); } ?>