Enregistrement des logs dans le repertoire data
This commit is contained in:
parent
ada634bdb1
commit
de6f69439a
@ -44,11 +44,13 @@ class IndexController extends Zend_Controller_Action
|
||||
$ws = new WsScores();
|
||||
$reponse = $ws->getPortefeuilleCsv($login, $idClient);
|
||||
|
||||
$log = Zend_Registry::get('configuration')->path->data.'/log/altisys.log';
|
||||
|
||||
if ($reponse === false){
|
||||
file_put_contents('altisys.log', date('Y-m-d H:i:s')." - URL = ERREUR\n", FILE_APPEND);
|
||||
file_put_contents($log, date('Y-m-d H:i:s')." - URL = ERREUR\n", FILE_APPEND);
|
||||
echo "Erreur";
|
||||
} elseif (!empty($reponse->result->Url)) {
|
||||
file_put_contents('altisys.log', date('Y-m-d H:i:s')." - URL = ".$reponse->result->Url."\n", FILE_APPEND);
|
||||
file_put_contents($log, date('Y-m-d H:i:s')." - URL = ".$reponse->result->Url."\n", FILE_APPEND);
|
||||
echo $reponse->result->Url;
|
||||
}
|
||||
}
|
||||
|
@ -19,7 +19,5 @@ if (!empty($login) && !empty($hach)){
|
||||
$url = $url.'?'.$login.'&'.$hach;
|
||||
}
|
||||
|
||||
file_put_contents('altisys.log', date('Y-m-d H:i:s')." - Connexion ".$_REQUEST['login']."\n", FILE_APPEND);
|
||||
|
||||
header( "Location: $url" );
|
||||
exit;
|
Loading…
Reference in New Issue
Block a user