How would i get wamp to display a login to the database? at the minuite you can load it directly from localhost but does not have a login.. obviously i want this for security reasons when it goes live, if this something you do now or when it goes live? and if so how do i do it??
Also what is the standard connection for PHP files regarding wamp
obviously the server name is localhost but what is the default password?
no doubt that the online databse will have the user name and password.
But if you are going to launch this solution on your own server in that case you have to change the password.
NeoAshura
ASKER
thanks ill try using the following...
<?php
//error_reporting(E_ALL);
// CONNECTION AND SELECTION VARIABLES FOR THE DATABASE
$db_host = "localhost";
$db_name = "DATABASENAME HERE";
$db_user = "root";
$db_word = "";
// OPEN A CONNECTION TO THE DATA BASE SERVER
if (!$db_connection = mysql_connect("$db_host", "$db_user", "$db_word"))
{
$errmsg = mysql_errno() . ' ' . mysql_error();
echo "<br/>NO DB CONNECTION: ";
echo "<br/> $errmsg <br/>";
}
if (!$db_sel = mysql_select_db($db_name, $db_connection))
{
$errmsg = mysql_errno() . ' ' . mysql_error();
echo "<br/>NO DB SELECTION: ";
echo "<br/> $errmsg <br/>";
die('NO DATA BASE');
}
// IF WE GOT THIS FAR WE CAN DO QUERIES
But if you are going to launch this solution on your own server in that case you have to change the password.