ok i have done this a hundred times but tonight can’t get it to work
here is the non-secure code for testing
[php]//Database Connect--------------------------
$link = mysql_connect(‘localhost’, ‘usernamegoeshere’, ‘pwdgoeshere’, ‘dbnamegoeshere’);
if (!$link)
{ die(‘Connect Error (’ . mysql_connect_errno() . ') ’ . mysql_connect_error()); }
echo 'Connected… ’ . mysql_get_host_info($link) . “\n”;
//this echoes that it is connected just fine…but then…
$db_selected = mysql_select_db(‘databasenamegoeshere’, $link);
if (!$db_selected) {
die ('Can’t use databasenamegoeshere : ’ . mysql_error());
}
//and it simply won’t do this query the error is denied because username is denied access
/
$query = "INSERT INTO tablenamehere (allthisstuff, etc)
[/php]
yes i have:
- connected to server just fine without query involved
- connected to server and printed out db list
but when i try to access this db for anything i am denied
checked and rechecked all usernames and pwds
any suggestions?
thanks