Fixing folder creation bug

skala
Julio Montoya 14 years ago
parent f38198c641
commit 2da70aaa81
  1. 1
      main/document/document.inc.php
  2. 1
      main/document/document.php

@ -760,6 +760,7 @@ function create_dir_form($current_dir_id) {
global $document_id;
$form = new FormValidator('create_dir_form', 'post', '', '', null, false);
$form->addElement('hidden', 'create_dir', 1);
$form->addElement('hidden', 'dir_id', intval($document_id));
$form->addElement('hidden', 'id', intval($current_dir_id));
$form->addElement('header', '', get_lang('CreateDir'));

@ -725,6 +725,7 @@ if($is_allowed_to_edit || $group_member_with_upload_rights || is_my_shared_folde
//Only teacher and all users into their group and any user into his/her shared folder
if ($is_allowed_to_edit || $group_member_with_upload_rights || is_my_shared_folder(api_get_user_id(), $curdirpath, $session_id)) {
// Create directory with $_POST data
if (isset($_POST['create_dir']) && $_POST['dirname'] != '') {
// Needed for directory creation
$post_dir_name = $_POST['dirname'];

Loading…
Cancel
Save