bonjour,
j'utilise le script php suivant pour peupler mon base de données
./batch/load_data.php
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 <?php define('SF_ROOT_DIR', realpath(dirname(__FILE__).'/..')); define('SF_APP', 'frontend'); define('SF_ENVIRONMENT', 'dev'); define('SF_DEBUG', true); require_once(SF_ROOT_DIR.DIRECTORY_SEPARATOR.'apps'.DIRECTORY_SEPARATOR.SF_APP.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php'); // initialize database manager $databaseManager = new sfDatabaseManager(); $databaseManager->initialize(); $data = new sfPropelData(); $data->loadData(sfConfig::get('sf_data_dir').DIRECTORY_SEPARATOR.'fixtures'); ?>
lorsque je lance la commande php load_data.php
j'ai les erreurs suivante
Code x : Sélectionner tout - Visualiser dans une fenêtre à part
1
2 Warning: require_once(/var/www/workspace/sf_sandbox/apps/frontend/config/config.php): failed to open stream: No such file or directory in /var/www/workspace/sf_sandbox/batch/load_data.php on line 7 Fatal error: require_once(): Failed opening required '/var/www/workspace/sf_sandbox/apps/frontend/config/config.php' (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/workspace/sf_sandbox/batch/load_data.php on line 7
apparemment le fichier config.php n'existe pas !mais je trouve pas un autre fichier de configuration sauf ProjectConfiguration.class.php qui me donne le meme resultat
NB : j'utilise le projet vide sandbox1.2
Partager