the user who left instructions for the flashbook just left this at the end for us : 4. Open connections.php from includes folder and change the $host, $dbusername, $dbpassword according to your Mysql configuration. That's it!
Now i've tried and tried to get this to work by changing the values this person asked for + more but idk...overall i'm lost. heres what the user wants me to input :
<?php
//connection.php
$host = "localhost";//Replace with your host name
$dbusername = "xxxxxx";//Replace with your database user name
$dbpassword = "xxxxxx";//Replace with your database password
$dbname = "guestbook"; //Replace with your database name
function db_connect()
{
global $host,$dbusername,$dbpassword,$dbname;
if(!($link_id=mysql_pconnect($host,$dbusername,$dbpassword)))
{
echo("error connecting to host");
exit();
}
// Select the Database
if(!mysql_select_db($dbname,$link_id))
{
echo("error in selecting the database");
echo(sprintf("Error : %d %s",mysql_errno($link_id),mysql_error($link_id)));
}
return $link_id;
}
So what exactly do i do?
