Проблемка с .htaccess в фаловой системе (Drupal 5.7)

Главные вкладки

Аватар пользователя ProMax ProMax 28 июня 2008 в 7:40

Дело в том что не зависимо какой способ доступа к файловой системе выбераешь приватный или публичный файл htaccess создается один и тот же и список содержимого папки файловой системы отображается в любом случае

SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
Options None
Options +FollowSymLinks

причем что странно даже если отредактировать таким образом

Options -Indexes

результата нет , пробовал его вообще удалить из папки files по умолчанию оставить только в корневом каталоге Drupal с Options -Indexes
и все по прежнему возможно что то не то в коде файла file.inc
приведу часть этого файла

 if (!is_writable($directory)) {
    if (($mode & FILE_MODIFY_PERMISSIONS) && [user=chmod]chmod[/user]($directory, 0775)) {
      drupal_set_message(t('The permissions of directory %directory have been changed to make it writable.', array('%directory' => $directory)));
    }
    else {
      form_set_error($form_item, t('The directory %directory is not writable', array('%directory' => $directory)));
      watchdog('file system', t('The directory %directory is not writable, because it does not have the correct permissions set.', array('%directory' => $directory)), WATCHDOG_ERROR);
      return FALSE;
    }
  }
  if ((file_directory_path() == $directory || file_directory_temp() == $directory) && !is_file("$directory/.htaccess")) {
    $htaccess_lines = "SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006\nOptions None\nOptions +FollowSymLinks";
    if (($fp = fopen("$directory/.htaccess", 'w')) && fputs($fp, $htaccess_lines)) {
      fclose($fp);
      chmod($directory .'/.htaccess', 0664);
    }
    else {
      $message = t("Security warning: Couldn't write .htaccess file. Please create a .htaccess file in your %directory directory which contains the following lines: <code>!htaccess

", array('%directory' => $directory, '!htaccess' => '
'. nl2br(check_plain($htaccess_lines))));
form_set_error($form_item, $message);
watchdog('security', $message, WATCHDOG_ERROR);
}
}

return TRUE;
}

Помогите разобраться

Комментарии