<?php

// You host should be able to provide you with these settings if you do not know them already

$db_username = 'murdockj';  // Your database login username
$db_password = 'P@nel673trap';  // Your database login password
$db_name = 'devworks';      // The name of the database you wish to use
$db_host = 'localhost';   // The address of the database. Often this is localhost, but may be for example db.yoursite.com

//////////////////////////////////////////////////
// Please do not edit anything below this line. //
//////////////////////////////////////////////////

if(!function_exists('mysqli_connect')){
	die('<html><body>mySQLi is not enabled in PHP. Please contact your host.</body></html>');
}else{
	$GLOBALS['ectdatabase'] = new mysqli($db_host, $db_username, $db_password, $db_name);
	if(mysqli_connect_error()){
		ob_clean();
		print '<html><head><title>Database connect error</title><style>div{ margin:20px }</style></head>';
		print '<body><div>Database Connect Error (' . mysqli_connect_errno() . ') ' . mysqli_connect_error() . '</div>';
		print '<div>You need to set your database connection in vsadmin/db_conn_open.php</div>';
		print '<div>For help setting your database connection please see...<br />';
		print '<a href="https://www.ecommercetemplates.com/phphelp/ecommplus/instructions.asp#dbconn" target="_blank">Database Connection Instructions</a></div>';
		print '<div>We also have a support forum here...<br />';
		print '<a href="https://www.ecommercetemplates.com/support/" target="_blank">Support Forum</a></div>';
		die('</body></html>');
	}
}
?>
