//Set no caching
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
//$link;
//connectToDB();
$today = date( 'Y-m-d H:i:s' );
$DBHost="www-db1.it.ohio-state.edu";
$DBUser="barlow2";
$DBname = "moritzdb2";
$DBPass="M0ritzL4w@55";
//if ( $today > '2013-11-06 22:00:00' ) :
// $DBPass="M0ritzL4w@55";
//else :
// $DBPass="barlow4u";
//endif;
global $link;
// Newly Added 4-21-2020 to replace deprecated mysql_pconnect
// Create connection
//$link = new mysqli("$DBHost", "$DBUser", "$DBPass","$DBname");
// Check connection
//if ($link->connect_error) {
// die("Connection failed: " . $conn->connect_error);
//}
// wasn't working?
// probably because a ton of old stuff is not using mysqli and updating this would require significant rewrites
//$link = mysqli_connect( "$DBHost", "$DBUser", "$DBPass")
//or die ('I cannot connect to the database because: ' . mysqli_error($link));
//mysqli_select_db ($link,"moritzdb2")
//or die ('Cant connect to moritz database because: ' . mysqli_error($link));
$link = mysql_pconnect( "$DBHost", "$DBUser", "$DBPass")
or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db ("moritzdb2", $link)
or die ('Cant connect to moritz database because: ' . mysql_error());
error_reporting(0);
?>
Election Law @ Moritz - Weekly Comment (Lying to Win - September 21, 2004)
Commentary...
// Comment Archive text
?>
//Set no caching
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
//$link;
//connectToDB();
$today = date( 'Y-m-d H:i:s' );
$DBHost="www-db1.it.ohio-state.edu";
$DBUser="barlow2";
$DBname = "moritzdb2";
$DBPass="M0ritzL4w@55";
//if ( $today > '2013-11-06 22:00:00' ) :
// $DBPass="M0ritzL4w@55";
//else :
// $DBPass="barlow4u";
//endif;
global $link;
// Newly Added 4-21-2020 to replace deprecated mysql_pconnect
// Create connection
//$link = new mysqli("$DBHost", "$DBUser", "$DBPass","$DBname");
// Check connection
//if ($link->connect_error) {
// die("Connection failed: " . $conn->connect_error);
//}
// wasn't working?
// probably because a ton of old stuff is not using mysqli and updating this would require significant rewrites
//$link = mysqli_connect( "$DBHost", "$DBUser", "$DBPass")
//or die ('I cannot connect to the database because: ' . mysqli_error($link));
//mysqli_select_db ($link,"moritzdb2")
//or die ('Cant connect to moritz database because: ' . mysqli_error($link));
$link = mysql_pconnect( "$DBHost", "$DBUser", "$DBPass")
or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db ("moritzdb2", $link)
or die ('Cant connect to moritz database because: ' . mysql_error());
error_reporting(0);
?>