From 9b29dd74676177909d7081458cea61a4dd8de0ff Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Fri, 18 Nov 2011 10:29:04 +0000 Subject: [PATCH] =?UTF-8?q?#168=20:=20recherche=20activit=C3=A9=20analytiq?= =?UTF-8?q?ue=20:=20Plan=20analytique=20n'existe=20pas?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- include/ajax_anc_search.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/ajax_anc_search.php b/include/ajax_anc_search.php index 4850b686f..d133e31d6 100644 --- a/include/ajax_anc_search.php +++ b/include/ajax_anc_search.php @@ -37,7 +37,7 @@ require_once ('class_dossier.php'); require_once ('class_anc_account.php'); require_once ('class_anc_plan.php'); require_once('function_javascript.php'); - +var_dump($_GET); echo HtmlInput::title_box("Recherche activité", $ctl); //------------- FORM ---------------------------------- @@ -65,9 +65,9 @@ if ( isset($_REQUEST['go'])) exit("Ce plan n'existe pas"); $sql="select po_name , po_description from poste_analytique ". - "where pa_id=".$_REQUEST['c2']." and ". - " upper (po_name) like upper('%".Database::escape_string($_REQUEST['label'])."%') order by po_name"; - $res=$cn->exec_sql($sql); + "where pa_id=$1 and ". + " upper (po_name) like upper('%'||$2||'%') order by po_name"; + $res=$cn->exec_sql($sql,array($_REQUEST['c2'],$_REQUEST['label'])); $array=Database::fetch_all($res); if (empty($array) == true) {