diff options
-rwxr-xr-x | dwsim_flowsheet.module | 2 | ||||
-rwxr-xr-x | upload_code.inc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/dwsim_flowsheet.module b/dwsim_flowsheet.module index 4636471..52a0c42 100755 --- a/dwsim_flowsheet.module +++ b/dwsim_flowsheet.module @@ -793,7 +793,7 @@ function _df_dir_name($project, $proposar_name) $project_title = ucname($project); $proposar_name = ucname($proposar_name); $dir_name = $project_title . ' By ' . $proposar_name; - $directory_name = str_replace("__", "_", str_replace(" ", "_", $dir_name)); + $directory_name = str_replace("__", "_", str_replace(" ", "_", str_replace("/","_", trim($dir_name)))); return $directory_name; } function dwsim_flowsheet_document_path() diff --git a/upload_code.inc b/upload_code.inc index e2bb22f..f27f602 100755 --- a/upload_code.inc +++ b/upload_code.inc @@ -841,7 +841,7 @@ function dwsim_flowsheet_upload_abstract_code_form_submit($form, &$form_state) case 'S': if (file_exists($root_path . $dest_path . $_FILES['files']['name'][$file_form_name])) { - unlink($root_path . $dest_path . $_FILES['files']['name'][$file_form_name]); + //unlink($root_path . $dest_path . $_FILES['files']['name'][$file_form_name]); drupal_set_message(t("File !filename already exists hence overwirtten the exisitng file ", array( '!filename' => $_FILES['files']['name'][$file_form_name] )), 'error'); |