Hello !
Help me, please !! It's driving me mad !
I've got that code here :
Code:
<?php
require ('database_site.php');
$monde ='ALPHA'; //database name
$nom_url_fichiers = array(
array( 'Index' => "fichier1",
'Nom_Table' => "alpha_alliances",
'Url_Fichier' => "/home/a6536850/public_html/fr/stats/cron/alliances.txt"
),
array( 'Index' => "fichier2",
'Nom_Table' => "alpha_towns",
'Url_Fichier' => "fr/stats/mondes/$monde/data/towns.txt"
),
array( 'Index' => "fichier3",
'Nom_Table' => "alpha_players",
'Url_Fichier' => "../mondes/$monde/data/players.txt"
),
array( 'Index' => "fichier4",
'Nom_Table' => "alpha_conquers",
'Url_Fichier' => "../mondes/$monde/data/conquers.txt"
),
array( 'Index' => "fichier5",
'Nom_Table' => "alpha_player_kills_att",
'Url_Fichier' => "../mondes/$monde/data/player_kills_att.txt"
),
array( 'Index' => "fichier6",
'Nom_Table' => "alpha_player_kills_def",
'Url_Fichier' => "../mondes/$monde/data/player_kills_def.txt"
),
array( 'Index' => "fichier7",
'Nom_Table' => "alpha_player_kills_all",
'Url_Fichier' => "../mondes/$monde/data/player_kills_all.txt"
),
array( 'Index' => "fichier8",
'Nom_Table' => "alpha_alliance_kills_att",
'Url_Fichier' => "../mondes/$monde/data/alliance_kills_att.txt"
),
array( 'Index' => "fichier9",
'Nom_Table' => "alpha_alliance_kills_def",
'Url_Fichier' => "../mondes/$monde/data/alliance_kills_def.txt"
),
array( 'Index' => "fichier10",
'Nom_Table' => "alpha_alliance_kills_all",
'Url_Fichier' => "../mondes/$monde/data/alliance_kills_all.txt"
),
);
foreach( $nom_url_fichiers as $fichiers ) {
$urlfichier = $fichiers['Url_Fichier'] or die('non mis à jour1'.mysql_error());
$nomtable = $fichiers['Nom_Table'] or die('non mis à jour2'.mysql_error());
mysql_query("TRUNCATE TABLE $nomtable") or die('non mis à jour3'.mysql_error());
$sql = "LOAD DATA INFILE '$urlfichier' INTO TABLE $nomtable FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '\"' ESCAPED BY '\\\\' LINES TERMINATED BY '\\n'" or die('non mis à jour4'.mysql_error());
mysql_query($sql) or die('Problème avec LOAD DATA INFILE</br></br>'.mysql_error());
}
echo ' Rendez-vous dans 1 h pour la prochaine MAJ !';
?>
And it returns me :
Quote:
Problème avec LOAD DATA INFILE
Access denied for user 'a6536850_gt'@'10.1.1.17' (using password: YES)
|
The files exists, I tried the full path links ... nothing
Host, username, password is fine ! not localhost ... and the support told me that it was allowed ...
PLEASE HELP !!!!