Obsolete functions
authorarjen <arjen>
Fri, 21 Feb 2003 08:50:37 +0000 (08:50 +0000)
committerarjen <arjen>
Fri, 21 Feb 2003 08:50:37 +0000 (08:50 +0000)
src/web/functions.php [deleted file]

diff --git a/src/web/functions.php b/src/web/functions.php
deleted file mode 100755 (executable)
index 94be9ac..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php 
-/**************************************************************************
-** This is free software; you can redistribute it and/or modify it under the
-** terms of the GNU General Public License, see the file COPYING.
-***************************************************************************/
-/******************************************************************************************/
-/* global parameters                                                                      */
-/******************************************************************************************/
-       //$pgsqlhost  = "10.10.10.145"; // PostgreSQL server
-       //$pgsqlport  = "5432";         // PostgreSQL port
-       //$dbname     = "gnucomo";      // PostgreSQL database name
-
-/******************************************************************************************/
-/* string function login_form( void )                                                     */
-/*                                                                                        */
-/* returns the login form                                                                 */
-/******************************************************************************************/
-function login_form() {
-
-       $login  = "<div class='login'>";
-       $login .= "<h1 align=\"center\">GNU Computer Monitoring</h1>";
-       $login .= "<h4 align=\"center\"><i>Version 0.0.4, Februari 05, 2003</i></h4>";
-       $login .= "<center><table>";
-       $login .= "<tr>";
-       $login .= "<td width='50%'><img src='logo.png' alt='GnuCoMo logo'></td>";
-       $login .= "<td><form name=\"login\" method=\"POST\" action=\"login.php\">";
-       $login .= "    <table>";
-       $login .= "    <tr>";
-       $login .= "    <td>Username</td>";
-       $login .= "    <td><input type=\"text\" name=\"username\"></td>";
-       $login .= "    </tr>";
-       $login .= "    <tr>";
-       $login .= "    <td>Password</td>";
-       $login .= "    <td><input type=\"password\" name=\"password\"></td>";
-       $login .= "    </tr>";
-       $login .= "    <tr>";
-       $login .= "    <td>&nbsp;</td>";
-       $login .= "    <td align=\"right\"><input type=\"submit\" value=\"signin\"></td>";
-       $login .= "    </tr>";
-       $login .= "    </table>";
-       $login .= "    </form>";
-       $login .= "</td>";
-       $login .= "</tr>";
-       $login .= "</table></center>";
-       $login .= "</div>";
-
-       return $login;
-}
-
-/******************************************************************************************/
-/* array function query( resource connection, string sqlquery )                           */
-/*                                                                                        */
-/* gives an array return.                                                                 */
-/* arr[0] = boolean if action completed whitout error, return true otherwise false        */
-/* arr[1] = result  sql query result                                                      */
-/* arr[2] = int     number of rows                                                        */
-/* arr[3] = string  error information                                                     */
-/******************************************************************************************/
-function query( $conn, $sql ) {
-
-       $query_result = pg_exec( $conn, $sql );
-
-       if( $query_result != FALSE ) {
-               $query_nRows = pg_NumRows($query_result);
-               $query_error = pg_errormessage( $conn );
-               return array( TRUE, $query_result, $query_nRows, "" );
-       } else {
-               $query_error = @pg_errormessage( $conn );
-               return array( FALSE, $query_result, 0, $query_error );
-       }
-}
-
-/******************************************************************************************/
-/* void function pgsql_error( string error )                                              */
-/*                                                                                        */
-/* prints an error message                                                                */
-/******************************************************************************************/
-function pgsql_error( $err ) {
-       echo "An error occured. Please contact your systemadministrator.<br>";
-       echo "Error: $err";
-}
-?>