diff options
-rw-r--r-- | etc/inc/pkg-utils.inc | 11 | ||||
-rwxr-xr-x | usr/local/www/pkg_mgr_install.php | 6 |
2 files changed, 16 insertions, 1 deletions
diff --git a/etc/inc/pkg-utils.inc b/etc/inc/pkg-utils.inc index 42f58ca..aceeb07 100644 --- a/etc/inc/pkg-utils.inc +++ b/etc/inc/pkg-utils.inc @@ -442,6 +442,17 @@ function install_package($package, $pkg_info = "") { $restart_sync = true; } +function get_after_install_info($package) { + global $pkg_info; + /* fetch package information if needed */ + if(!$pkg_info or !is_array($pkg_info[$package])) { + $pkg_info = get_pkg_info(array($package)); + $pkg_info = $pkg_info[$package]; // We're only dealing with one package, so we can strip away the extra array. + } + if($pkg_info['after_install_info']) + return $pkg_info['after_install_info']; +} + function eval_once($toeval) { global $evaled; if(!$evaled) $evaled = array(); diff --git a/usr/local/www/pkg_mgr_install.php b/usr/local/www/pkg_mgr_install.php index 603ff3f..4ea6819 100755 --- a/usr/local/www/pkg_mgr_install.php +++ b/usr/local/www/pkg_mgr_install.php @@ -179,7 +179,11 @@ switch($_GET['mode']) { $static_output .= "\n\nInstallation halted."; } else { update_status("Installation of " . htmlspecialchars($_GET['id']) . " completed."); - $static_output .= "\n\nInstallation completed. Please check to make sure that the package is configured from the respective menu then start the package."; + $status = get_after_install_info($_GET['id']); + if($status) + $static_output .= "\nInstallation completed.\n\n{$_GET['id']} setup instructions:\n\n{$status}"; + else + $static_output .= "\nInstallation completed. Please check to make sure that the package is configured from the respective menu then start the package."; } update_output_window($static_output); } |