Platform  3.1
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
Fgsearch/fulldsearch.php
Go to the documentation of this file.
1 <?php
2 /*
3  * @author Anakeen
4  * @license http://creativecommons.org/licenses/by-nc-sa/2.0/fr/ Anakeen - licence CC
5  * @package FDL
6 */
7 /**
8  * Full Text Search document
9  *
10  * @author Anakeen 2007
11  * @version $Id: fulldsearch.php,v 1.2 2007/12/06 10:51:35 eric Exp $
12  * @license http://creativecommons.org/licenses/by-nc-sa/2.0/fr/ Anakeen - licence CC
13  * @package FDL
14  * @subpackage GED
15  */
16 /**
17  */
18 
19 include_once ("FGSEARCH/fullsearchresult.php");
20 include_once ("FDL/modcard.php");
21 /**
22  * Fulltext Search document
23  * @param Action &$action current action
24  * @global keyword Http var : word to search in any values
25  * @global famid Http var : restrict to this family identioficator
26  * @global start Http var : page number
27  * @global dirid Http var : search identificator
28  */
29 function fulldsearch(&$action)
30 {
31 
32  $famid = GetHttpVars("famid", 0);
33 
34  $dbaccess = $action->GetParam("FREEDOM_DB");
35 
36  if ($famid > 0) {
37  $fdoc = new_doc($dbaccess, $famid);
38  if (!$fdoc->isAffected()) $action->exitError(sprintf(_("Family %s not exist") , $famid));
39  $search = createTmpDoc($dbaccess, 16);
40  $search->setValue("se_famid", $famid);
41  $search->setValue("se_latest", "yes");
42 
43  setPostVars($search);
44 
45  $err = $search->Add();
46 
47  if ($err != "") $action->exitError($err);
48  $search->SpecRefresh();
49 
50  setHttpVar("dirid", $search->id);
52  }
53 }
54 ?>
← centre documentaire © anakeen - published under CC License - Dynacase