1 | <?php |
---|
2 | include("../inc/inc.Settings.php"); |
---|
3 | include("../inc/inc.AccessUtils.php"); |
---|
4 | include("../inc/inc.ClassAccess.php"); |
---|
5 | include("../inc/inc.ClassDocument.php"); |
---|
6 | include("../inc/inc.ClassFolder.php"); |
---|
7 | include("../inc/inc.ClassGroup.php"); |
---|
8 | include("../inc/inc.ClassUser.php"); |
---|
9 | include("../inc/inc.DBAccess.php"); |
---|
10 | include("../inc/inc.FileUtils.php"); |
---|
11 | include("../inc/inc.Language.php"); |
---|
12 | include("../inc/inc.OutUtils.php"); |
---|
13 | |
---|
14 | include("../inc/inc.Authentication.php"); |
---|
15 | |
---|
16 | |
---|
17 | |
---|
18 | |
---|
19 | $folderid = (isset($_GET['folderid'])) ? (int) $_GET['folderid'] : 1; |
---|
20 | $folder = getFolder($folderid); |
---|
21 | |
---|
22 | |
---|
23 | if ($folder->getAccessMode($user) < M_READWRITE) |
---|
24 | die("accesso denegado"); |
---|
25 | |
---|
26 | |
---|
27 | printHTMLHead( getMLText("folder_title", array("foldername" => $folder->getName()) ) ); |
---|
28 | ?> |
---|
29 | |
---|
30 | <script language="JavaScript"> |
---|
31 | function checkForm() |
---|
32 | { |
---|
33 | msg = ""; |
---|
34 | if (document.form1.name.value == "") msg += "<?php printMLText("js_no_name");?>\n"; |
---|
35 | if (document.form1.comment.value == "") msg += "<?php printMLText("js_no_comment");?>\n"; |
---|
36 | if (msg != "") |
---|
37 | { |
---|
38 | alert(msg); |
---|
39 | return false; |
---|
40 | } |
---|
41 | else |
---|
42 | return true; |
---|
43 | } |
---|
44 | </script> |
---|
45 | |
---|
46 | <?php |
---|
47 | printTitleBar($folder); |
---|
48 | printFolderPageStart($folder); |
---|
49 | printPageHeader(lang(getMLText("add_subfolder")) . ": " . $folder->getName()); |
---|
50 | |
---|
51 | printStartBox(lang(getMLText("add_subfolder"))); |
---|
52 | ?> |
---|
53 | |
---|
54 | <form action="../op/op.AddSubFolder.php" name="form1" onsubmit="return checkForm();"> |
---|
55 | <input type="Hidden" name="folderid" value="<?php print $folderid;?>"> |
---|
56 | <table border="0" width="100%"> |
---|
57 | <tr> |
---|
58 | <td class="inputDescription" width="150px"><?php echo lang("name");?>:</td> |
---|
59 | <td><input name="fname" style="width: 100%;"></td> |
---|
60 | </tr> |
---|
61 | <tr> |
---|
62 | <td valign="top" class="inputDescription"><?php echo lang("comment");?>:</td> |
---|
63 | <td><textarea name="comment" rows="4" style="width: 100%;"></textarea></td> |
---|
64 | </tr> |
---|
65 | <tr> |
---|
66 | <td class="inputDescription"><?php echo lang("sequence");?>:</td> |
---|
67 | <td><?php printSequenceChooser($folder->getSubFolders());?></td> |
---|
68 | </tr> |
---|
69 | <tr> |
---|
70 | <td colspan="2"><br><input type="Submit"></td> |
---|
71 | </tr> |
---|
72 | </table> |
---|
73 | </form> |
---|
74 | |
---|
75 | |
---|
76 | <?php |
---|
77 | |
---|
78 | printEndBox(); |
---|
79 | printFolderPageEnd($folder); |
---|
80 | printHTMLFoot(); |
---|
81 | |
---|
82 | ?> |
---|