AlaK4X
Linux lhjmq-records 5.15.0-118-generic #128-Ubuntu SMP Fri Jul 5 09:28:59 UTC 2024 x86_64



Your IP : 3.145.152.49


Current Path : /var/www/lhjmq-records.qc.ca/public_html/administration/includes/
Upload File :
Current File : /var/www/lhjmq-records.qc.ca/public_html/administration/includes/mysql_connect.php.pre-netsimplify

<?php
//Check if on wrong server, you should never be on .27 in the admin, cause any mod will stop replication
if($_SERVER['SERVER_ADDR'] == '204.19.191.27'){
	//Connection data
	$mysql_host = "localhost";
	$mysql_user = "lhjmq_readonly";
	$mysql_pass = "45GhiLk19cQ";
	$mysql_db = "lhjmq_pii";
	$stat_db = "lhjmqstats_pii";
}else{
	//Connection data
	$mysql_host = "localhost";
	$mysql_user = "lhjmq";
	$mysql_pass = "45GhiLk19cQ";
	$mysql_db = "lhjmq_pii";
	$stat_db = "lhjmqstats_pii";
}

//Connection to database
$mysql_link = mysql_connect("$localhost", "$mysql_user", "$mysql_pass");
if(!$mysql_link){
	//Display an error message
	echo "Error connecting to mysql server, contact web administrator or try again later!";
	exit();
}

//Select the database
if(!mysql_select_db("$mysql_db", $mysql_link)){
	//Display an error message
	echo "Error selecting database on mysql server, contact web administrator or try again later!";
	exit();
}

//Set the character sets
mysql_query('SET character_set_results = latin1', $mysql_link);
mysql_query('SET character_set_client = latin1', $mysql_link);
?>