Platform  3.1
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
revision.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  * Generated Header (not documented yet)
9  *
10  * @author Anakeen 2000
11  * @version $Id: revision.php,v 1.9 2005/06/28 08:37:46 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 // $Id: revision.php,v 1.9 2005/06/28 08:37:46 eric Exp $
20 // $Source: /home/cvsroot/anakeen/freedom/freedom/Action/Freedom/revision.php,v $
21 // ---------------------------------------------------------------
22 include_once ("FDL/Class.Doc.php");
23 include_once ("FDL/Class.DocAttr.php");
24 function revision(&$action)
25 {
26  $dbaccess = $action->GetParam("FREEDOM_DB");
27  $docid = GetHttpVars("id", 0);
28  $comment = GetHttpVars("comment", _("no comment"));
29 
31 
32  $err = $doc->canEdit();
33  if ($err != "") $action->ExitError($err);
34 
35  $err = $doc->Addrevision($comment);
36  if ($err != "") $action->ExitError($err);
37 
38  $action->AddLogMsg(sprintf(_("%s new revision %d") , $doc->title, $doc->revision));
39 
40  redirect($action, "FDL", "FDL_CARD&refreshfld=Y&id=" . $doc->id, $action->GetParam("CORE_STANDURL"));
41 }
42 ?>
← centre documentaire © anakeen - published under CC License - Dynacase