我正在使用 Joomla 1.5 并希望进行自定义分页。为此,我需要连接到数据库。
数据库连接.php:
<?php
/*Define constant to connect to database */
DEFINE('DATABASE_USER', 'padekime_db'); //this is my user's name
DEFINE('DATABASE_PASSWORD', 'myPassword');
DEFINE('DATABASE_HOST', 'hostingas.in');
DEFINE('DATABASE_NAME', 'padekime_db');
// Make the connection:
$dbc = @mysqli_connect(DATABASE_HOST, DATABASE_USER, DATABASE_PASSWORD,
DATABASE_NAME);
if (!$dbc) {
trigger_error('Could not connect to MySQL: ' . mysqli_connect_error());
}
?>
这是我收到的错误:
Notice: Could not connect to MySQL: Access denied for user 'padekime_db'@'neva.hostingas.in' (using password: YES) in /home/padekime/domains/juokoera.lt/public_html/components/com_allvideoshare/views/videos/tmpl/database_connection.php on line 16
有什么问题?