Main Page | Namespace List | Class Hierarchy | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

recherche.php

Go to the documentation of this file.
00001 <?
00002 /*
00003  *   This file is part of PhpCompta.
00004  *
00005  *   PhpCompta is free software; you can redistribute it and/or modify
00006  *   it under the terms of the GNU General Public License as published by
00007  *   the Free Software Foundation; either version 2 of the License, or
00008  *   (at your option) any later version.
00009  *
00010  *   PhpCompta is distributed in the hope that it will be useful,
00011  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  *   GNU General Public License for more details.
00014  *
00015  *   You should have received a copy of the GNU General Public License
00016  *   along with PhpCompta; if not, write to the Free Software
00017  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00018 */
00019 /* $Revision: 1.16 $ */
00020 // Copyright Author Dany De Bontridder ddebontridder@yahoo.fr
00021 include_once("ac_common.php");
00022 include("user_menu.php");
00023 include_once ("constant.php");
00024 include_once("jrn.php");
00025 include_once("user_common.php");
00026 include_once("class_widget.php");
00031 html_page_start($_SESSION['g_theme']);
00032 if ( ! isset ( $_SESSION['g_dossier'] ) ) {
00033   echo "You must choose a Dossier ";
00034   exit -2;
00035 }
00036 include_once ("postgres.php");
00037 include_once ("check_priv.php");
00038 /* Admin. Dossier */
00039 
00040 $cn=DbConnect($_SESSION['g_dossier']);
00041 include ('class_user.php');
00042 $User=new cl_user($cn);
00043 $User->Check();
00044 echo '<div class="u_tmenu">';
00045 echo ShowMenuCompta($_SESSION['g_dossier']);
00046 echo '</div>';
00047    // PhpSessid
00048    $sessid=$_REQUEST['PHPSESSID'];
00049 
00050 // display a search box
00051 $search_box=u_ShowMenuRecherche($cn,0,$sessid,$_GET);
00052 echo '<DIV class="lextmenu">'; // class="recherche_form">';
00053 echo $search_box;
00054 echo "</div>";
00055 //-----------------------------------------------------
00056 // Display search result
00057 //-----------------------------------------------------
00058 if ( isset ($_GET['viewsearch'])) {
00059   // Navigation bar
00060   $step=$_SESSION['g_pagesize'];
00061   $page=(isset($_GET['offset']))?$_GET['page']:1;
00062   $offset=(isset($_GET['offset']))?$_GET['offset']:0;
00063   if (count ($_GET) == 0) 
00064     $array=null;
00065   else
00066      $array=$_GET;
00067   
00068   list($max_line,$a)=ListJrn($cn,0,"",$array,$offset,2);
00069   $bar=jrn_navigation_bar($offset,$max_line,$step,$page);
00070 
00071   echo '<div class="u_redcontent">';
00072   echo $bar;
00073   echo $a;
00074   echo $bar;
00075   echo '</div>';
00076 }
00077 echo '</DIV>'; 
00078  
00079 ?>