Fixed db_import to allow select/delete queries in upgrade files.
[fa-stable.git] / admin / inst_module.php
index f467ce5f73ec81628f3cf832050a9d6e1e56f9c6..01169034e2563ff95b02e00efe67a59fb85e8db9 100644 (file)
@@ -14,10 +14,10 @@ $path_to_root="..";
 include_once($path_to_root . "/includes/session.inc");
 include_once($path_to_root."/includes/packages.inc");
 
-if ($use_popup_windows) {
+if ($SysPrefs->use_popup_windows) {
        $js = get_js_open_window(900, 500);
 }
-page(_($help_context = "Install/Activate extensions"));
+page(_($help_context = "Install/Activate extensions"), false, false, "", $js);
 
 include_once($path_to_root . "/includes/date_functions.inc");
 include_once($path_to_root . "/admin/db/company_db.inc");
@@ -42,8 +42,8 @@ function local_extension($id)
                        'active' => false
        );
 
-       if (file_exists($path_to_root.'/modules/'.$id.'/hooks.php')) {
-               include_once($path_to_root.'/modules/'.$id.'/hooks.php');
+       if (file_exists($path_to_root.'/modules/'.clean_file_name($id).'/hooks.php')) {
+               include_once($path_to_root.'/modules/'.clean_file_name($id).'/hooks.php');
        }
        $hooks_class = 'hooks_'.$id;
        if (class_exists($hooks_class, false)) {
@@ -113,13 +113,12 @@ function display_extensions()
                $available = @$ext['available'];
                $installed = @$ext['version'];
                $id = @$ext['local_id'];
-               $is_mod = $ext['type'] == 'module';
 
                $entries = fmt_titles(@$ext['entries']);
                $tabs = fmt_titles(@$ext['tabs']);
 
                alt_table_row_color($k);
-//             label_cell(is_array($ext['Descr']) ? $ext['Descr'][0] : $ext['Descr']);
+
                label_cell($available ? get_package_view_str($pkg_name, $ext['name']) : $ext['name']);
                label_cell($tabs);
                label_cell($entries);
@@ -267,4 +266,3 @@ else
 end_form();
 
 end_page();
-?>
\ No newline at end of file