dbdb, $this->dbhost, $this->dbuser, $this->dbpwd);
if (!$db->connect_id)
{
if (!headers_sent())
header("HTTP/1.0 500 Internal Server Error");
die("Could not connect to database (".mysql_error().")");
}
$this->db = $db;
}
/** Add some automatic hyperlinks to a text.
*
* @param in the text to beautify
*/
function urlise($in)
{
$out = str_replace("Polytechnique.org","Polytechnique.org",$in);
$out = str_replace("Diogenes","Diogenes",$out);
return $out;
}
}
/** Translation function.
*
* @param msg the message to translate
*/
function __($msg)
{
global $globals;
$func = $globals->gettext;
if (function_exists($func))
return $func($msg);
else
return $msg;
}
?>