All pastes #14369 Raw Edit

Mine

public php v1 · immutable
#14369 ·published 2005-06-13 20:09 UTC
rendered paste body
<?php	// Local class.	class Main	{				var $configuration; // Configuration		var $database; // Database		var $encryption; // Encryption		var $authentication; // Authentication						// Constructor		function __construct()		{			// Require files			require_once("class.database.php");			require_once("class.configuration.php");			require_once("class.encryption.php");			require_once("class.authenticate.php");			require_once("class.form.php");			require_once("class.data_adapter.php");						// Global stuff.			$this->database = new Database(SQL_HOST, SQL_USER, SQL_PASS, SQL_DB, $this);			$this->configuration = new Configuration($this);			$this->encryption = new Encryption($this);			$this->authentication = new Authenticate($this);		}				// Page redirect		function redirect($url)		{			header("Location: $url");		}				// Error		function error($title, $msg)		{			print("<table cellspacing='0' width='95%' align='center' style='border: 1px solid black;'>");			print("<tr style='background-color: #". FORM_COLOR_HEADER .";'>");			print("<td colspan=2 style='border-bottom: 1px solid black; padding: 4px;' align=center><b>$title</b></td></tr>");			print("<td colspan=2 style='background-color: ". FORM_COLOR_ONE ."; padding: 4px;'>");			print($msg);			print("</td></tr></table>");			if($_SESSION['admin'] == 1)				require_once("admins/footer.php");			else				require_once("clients/footer.php");			die();		}	}	?>