hello, all. i’m still working through it. it seems i’m running my head into a brick wall. i’m sure this must be one of the easiest thing to do in php and i can’t get it right.
i continue to get a 404 error when i know i uploaded the file using filezilla.
below is a image of the filezilla file structure for public_html. it clearly shows that the file is there. yet its not found… >:(
here is the connection script:
[php]<?php
/*** mysql hostname ***/
$hostname = ‘xxxx.co’;
/*** mysql username ***/
$username = ‘xxxx’;
/*** mysql password ***/
$password = ‘xxxx’;
try {
$dbh = new PDO(“mysql:host=$hostname;dbname=mysql”, $username, $password);
$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$dbh->setAttribute(PDO::ATTR_EMULATE_PREPARES, false);
$dbh->setAttribute(PDO::ERRMODE_EXCEPTION);
/*** echo a message saying we have connected ***/
echo ‘Connected to database
’;
}catch(PDOException $e) {
echo “An Error Occurred. The Error Is Being Processed!”; //user friendly message
some_logging_function($ex->getMessage());
}
?>[/php]
the error message comes when using this url: http://eyewasframed.co/public_html/prac.php
its driving me batty