From 9591b40aabbd121a80389c3d16c7302aaf66babc Mon Sep 17 00:00:00 2001 From: Michael RICOIS Date: Tue, 5 Jun 2012 15:22:18 +0000 Subject: [PATCH] Correction remplacement URL --- application/controllers/RechercheController.php | 2 +- application/controllers/TelechargementController.php | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/application/controllers/RechercheController.php b/application/controllers/RechercheController.php index 06df9d306..375da6a8f 100644 --- a/application/controllers/RechercheController.php +++ b/application/controllers/RechercheController.php @@ -193,7 +193,7 @@ class RechercheController extends Zend_Controller_Action 'annee' => $annonce->Annee, 'code' => $code, 'text' => $texte, - 'file' => $this->view->url(array('controller'=>'telechargement', 'action'=>'histopdf')).'/'.$fichier, + 'file' => $this->view->url(array('controller'=>'telechargement', 'action'=>'histopdf')).'/q/'.$fichier, ); } $this->view->assign('annonces', $annonces); diff --git a/application/controllers/TelechargementController.php b/application/controllers/TelechargementController.php index e32d77575..2ec130c84 100644 --- a/application/controllers/TelechargementController.php +++ b/application/controllers/TelechargementController.php @@ -224,11 +224,13 @@ class TelechargementController extends Zend_Controller_Action $url = "http://wse.scores-decisions.com:8081/fichier/bodacc/q"; + $q = $request->getParam('q', ''); + //Authenticate info $auth = Zend_Auth::getInstance(); $identity = $auth->getIdentity(); $authinfo = '?login='.$identity->username.'&hach='.$identity->password; - $url = $url.$authinfo; + $url = $url.'/'.$q.$authinfo; $file = $this->getFile($url);