
Sometimes you can not import the sql file because as field titles protected terms are used.
Solve the problem the following way:
1. Open the sql file in a text editor (eg. Notepad).
2. Put the field titles in ` (inverse accent: Shift and `)
For example:
CREATE TABLE `language` (
`id` int(11) NOT NULL auto_increment,
`msgid` varchar(20) NOT NULL default '0',
`lg` varchar(20) NOT NULL default '',
`msg` text NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY id (`id`)
) TYPE=MyISAM;
Open the file include.inc.php and look for the function connect_database().
If it looks like that:
function connect_database() {
$db_connection=@mysql_connect($db_server, $db_login, $db_password);
if(! $db_connection){
die("Error when connecting the database. Please check your login information!");
}
return $db_connection;
}
Then replace it with this:
function connect_database() {
global $db_server,$db_login,$db_password;
$db_connection=@mysql_connect($db_server, $db_login, $db_password);
if(! $db_connection){
echo mysql_error();
die("Error when connecting the database. Please check your login information!");
}
return $db_connection;
}
Top
|