From 39cef2800b533d7b64f072d4764850b3220383d4 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Tue, 8 Feb 2005 11:08:31 +0000 Subject: [PATCH] IMPROVE setup html based, ability to patch tested --- html/admin/setup.php | 28 +++++++++++++++++++++++++--- html/admin/sql/patch/upgrade4.sql | 9 +++++---- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/html/admin/setup.php b/html/admin/setup.php index ed89afbf2..806984445 100644 --- a/html/admin/setup.php +++ b/html/admin/setup.php @@ -41,6 +41,22 @@ include_once('postgres.php'); include_once('debug.php'); include_once('ac_common.php'); include_once('variable.php'); +/* function GetVersion + ************************************************** + * Purpose : Get version of a database + * + * parm : + * - $p_cn database connection + * gen : + * - none + * return: + * none + */ +function GetVersion($p_cn) { + $Res=ExecSql($p_cn,"select val from version"); + $a=pg_fetch_array($Res,0); + return $a['val']; +} /* function ExecuteScript ************************************************** * Purpose : Execute a sql script @@ -113,7 +129,13 @@ if ($cn == false ) { puis la base de données par défaut de phpcompta.

"; exit(); } - +?> +
+ +
+