Documentation is available at database.php
- <?
- /**
- * database.php
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- * @author Stephan Raabe
- */
- /**
- * returns a database connection
- * @return resource
- */
- function connectDB()
- {
- global $db_server, $db_user, $db_password, $db_name;
- $link = mysql_pconnect($db_server, $db_user, $db_password) or die("<script language='Javascript'>location.href='installation/index.php';</script>");
- mysql_select_db($db_name) or die("<script language='Javascript'>location.href='installation/index.php';</script>");
- return $link;
- }
- /**
- * returns the filename of a path
- */
- function closeDB($link)
- {
- mysql_close($link);
- }
- ?>
Documentation generated on Tue, 04 Oct 2005 11:13:38 +0200 by phpDocumentor 1.3.0RC3