Jump to content

Unknown PHP error (2) mysql_connect() [function.mysql-connect]


Trek15

Recommended Posts

If anyone could help me with this i'd be mighty grateful:

 

PHP version: 5.2.10

MySQL version: 5.0.81-community

 

Unknown PHP error (2)
mysql_connect() [function.mysql-connect]: Access denied for user 'myusername'@'localhost' (using password: YES)
File: .../install.php
Line: 584

 

if (empty($zcontext['e']))
		{
			// test db info...
			$connection = @mysql_connect($processed['db_server'], $processed['db_user'], $processed['db_passwd']);
			if (!$connection || !@mysql_select_db($processed['db_name'], $connection))
			{
				$zcontext['e'][] = $ztxt['install'][28];

				// so the input fields are highlighted in red
				$zcontext['e'][$ekeys['db_server']] = '';
				$zcontext['e'][$ekeys['db_user']] = '';
				$zcontext['e'][$ekeys['db_passwd']] = '';
				$zcontext['e'][$ekeys['db_name']] = '';
			}

put it in your script just above

 

$connection = @mysql_connect($processed['db_server'], $processed['db_user'], $processed['db_passwd']);

 

and run it. You should see info about your $processed array output on the screen.

:psychic:  I have no idea what script you are using.  You can tell me if you like, but I'm not going to go searching for it and then look over its code.. more than likely it simply doesn't accept non-alphanumeric chars in things like username, pw, etc...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.