Core  3.2
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
modexportchoosecols.php
Go to the documentation of this file.
1 <?php
2 /*
3  * @author Anakeen
4  * @package FDL
5 */
6 /**
7  * Save export preferences
8  *
9  * @author Anakeen
10  * @version $Id: modexportchoosecols.php,v 1.2 2008/11/14 12:41:43 eric Exp $
11  * @package FDL
12  * @subpackage GED
13  */
14 /**
15  */
16 
17 include_once ("FDL/Class.Doc.php");
18 include_once ("FDL/Lib.Dir.php");
19 include_once ("GENERIC/generic_util.php");
20 
22 {
23  $dbaccess = $action->dbaccess;
24  $docid = GetHttpVars("id");
25  $cols = GetHttpVars("ch");
26  $clear = (GetHttpVars("clear") == "yes");
27 
28  $doc = new_doc($dbaccess, $docid);
29  if (!$doc->isAlive()) $action->exitError(sprintf(_("family %s not exists") , $docid));
30 
31  if ($cols == "") $scols = array();
32  else $scols = implode(';', $cols);
33 
34  if ($clear) {
35  deleteFamilyParameter($action, $doc->id, "FREEDOM_EXPORTCOLS");
36  $action->addWarningMsg(_("export preferences has been cleared"));
37  } else {
38  setFamilyParameter($action, $doc->id, "FREEDOM_EXPORTCOLS", $scols);
39  $action->addWarningMsg(_("export preferences are saved"));
40  }
41  redirect($action, "FREEDOM", "EDITEXPORTCHOOSECOLS&id=" . $doc->id, $action->GetParam("CORE_STANDURL"));
42 }
addWarningMsg($msg)
global $action
modexportchoosecols(Action &$action)
exitError($texterr, $exit=true, $code="")
deleteFamilyParameter(Action &$action, $famid, $attrid)
$docid
Definition: cleanFamily.php:13
$dbaccess
Definition: checkVault.php:17
setFamilyParameter(Action &$action, $famid, $attrid, $value)
← centre documentaire © anakeen