- function Check( $support, $description, $error_message )
- {
- $result = $description . " </td>";
- $ok = false;
-
- switch( $support )
+ // Check result icon
+ $check_result = array( true => 's_ok.png', false => 's_error.gif' );
+
+ // Checks list
+ $check_list = array( array( 'check_cmd' => 'php-gettext',
+ 'check_label' => 'PHP - Gettext support',
+ 'check_descr' => 'If you want Bacula-web in your language, please compile PHP with Gettext support' ),
+ array( 'check_cmd' => 'pear-db',
+ 'check_label' => 'PEAR DB module',
+ 'check_descr' => 'PEAR DB support not found, please read the Bacula-web installation document'),
+ array( 'check_cmd' => 'php-gd',
+ 'check_label' => 'PHP - GD support',
+ 'check_descr' => 'This is required by phplot, please compile php with GD support'),
+ array( 'check_cmd' => 'smarty-cache',
+ 'check_label' => 'Smarty cache folder write permission',
+ 'check_descr' => 'Smarty template engine need write permissions to templates_c folder')
+ );
+
+ // Doing all checks
+ foreach( $check_list as &$check ) {
+ switch( $check['check_cmd'] )