如何使用Web文件管理器浏览服务器文件夹

时间:2021-12-31 14:30:35

I needed a web file manager able to navigate a given directory tree on a server. The best solution I could find was KCFinder available for free and considered reliable as long as I could read until now.

我需要一个能够在服务器上导航给定目录树的Web文件管理器。我能找到的最好的解决方案是KCFinder免费提供,只要我能读到现在就认为是可靠的。

So I downloaded the last stable versione (3.12) and made a basic installation on my server.

所以我下载了最后一个稳定版本(3.12)并在我的服务器上进行了基本安装。

I simply copied the whole kcfinder-3.12 folder in my wwwroot on a machine running Linux Debian+Apache+PHP5 then modified the kcfinder/conf/config.php so that any user was allowed to access:

我只是在运行Linux Debian + Apache + PHP5的机器上复制了我的wwwroot中的整个kcfinder-3.12文件夹,然后修改了kcfinder / conf / config.php,以便允许任何用户访问:

  'disabled' => false

The default settings for folders remained as follows:

文件夹的默认设置如下:

  'uploadURL' => "upload",
  'uploadDir' => "",

This should give me the right to browse, download and upload files located in the subfolder kcfinder/upload/

这应该让我有权浏览,下载和上传子文件夹中的文件kcfinder / upload /

But when I run the application, it actually shows me only the subfolder "files/" contained in the above said upload folder despite many other exists created via shell.

但是当我运行应用程序时,它实际上只向我显示上述所述上传文件夹中包含的子文件夹“files /”,尽管通过shell创建了许多其他文件。

I know this behaviour comes from the types settings:

我知道这种行为来自类型设置:

  'types' => array(

    // (F)CKEditor types
        'files'   =>  "",
        'flash'   =>  "swf",
        'images'  =>  "*img",

    // TinyMCE types
        'file'    =>  "",
        'media'   =>  "swf flv avi mpg mpeg qt mov wmv asf rm",
        'image'   =>  "*img",
    ), 

如何使用Web文件管理器浏览服务器文件夹

But it's not very clear to me how those categories are supposed to fit in my expectations and how I'm instead allowed to have a web based file browser with no restrictions starting from a given directory.

但是我不清楚这些类别应该如何符合我的期望,以及我如何允许拥有一个基于Web的文件浏览器,从给定目录开始没有任何限制。

Does anyone know what I'm doing wrong and if there's a way to get total access to a given directory? Here I talked about KCFinder but I'm available to listen any other option as long as it fulfills my request.

有谁知道我做错了什么,是否有办法获得对给定目录的完全访问权限?在这里我谈到了KCFinder,但只要满足我的要求,我就可以听任何其他选项。

2 个解决方案

#1


0  

What you really need are two things:

你真正需要的是两件事:

1) Enable DAV extensions on your web server. This consists simply of enabling the stock mod_dav module.

1)在Web服务器上启用DAV扩展。这仅包括启用库存mod_dav模块。

2) Use any DAV-based file manager. Heck, there's one even for Android: https://play.google.com/store/apps/details?id=jp.ddo.shigadroid.webdavfilemanager&hl=en

2)使用任何基于DAV的文件管理器。哎呀,甚至还有Android版:https://play.google.com/store/apps/details?id = jp.ddo.shigadroid.webdavfilemanager&hl = en

For native Linux, you don't need any special client software. A brief googling around suggests that current Gnome and KDE desktops can natively access remote files via the DAV protocol. Here's a random page Google came up with, with examples: http://doc.owncloud.org/server/6.0/user_manual/files/files.html

对于本机Linux,您不需要任何特殊的客户端软件。一个简短的谷歌搜索表明,当前的Gnome和KDE桌面可以通过DAV协议本地访问远程文件。这是Google提出的一个随机页面,其中包含示例:http://doc.owncloud.org/server/6.0/user_manual/files/files.html

I'm sure there are plenty of standalone DAV clients, that you can use to browse your web server via the DAV protocol, you can Google them up yourself.

我确信有很多独立的DAV客户端,您可以使用它们通过DAV协议浏览您的Web服务器,您可以自己谷歌它们。

Of course, there are some issues to work out here, regarding configuration, security, and permissions. You need to set aside some time to dig through mod_dav's documentation, and figure out exactly how you need your security setup to work.

当然,这里有一些问题需要解决,包括配置,安全性和权限。您需要留出一些时间来深入了解mod_dav的文档,并确切了解您需要安全设置如何工作。

#2


1  

A couple at things that could be doing that:

一对夫妇可能会这样做:

1) Check folder permissions

1)检查文件夹权限

2) Clear your browser cache and reload page

2)清除浏览器缓存并重新加载页面

3) And configurations from the documentation:

3)文档中的配置:

'uploadDir' => "",

This setting is used when KCFinder can't automatically detect its local filesystem path to the folder specified in uploadURL setting. Change this setting when KCFinder can't fetch the local filesystem path automatically.

当KCFinder无法自动检测其在uploadURL设置中指定的文件夹的本地文件系统路径时,将使用此设置。当KCFinder无法自动获取本地文件系统路径时,请更改此设置。

'dirPerms' => 0755,
'filePerms' => 0644,

Default filesystem permissions for new files and directories created with KCFinder. Windows servers will skip these settings.

使用KCFinder创建的新文件和目录的默认文件系统权限。 Windows服务器将跳过这些设置。

More Information in: http://kcfinder.sunhater.com/install

更多信息请访问:http://kcfinder.sunhater.com/install

#1


0  

What you really need are two things:

你真正需要的是两件事:

1) Enable DAV extensions on your web server. This consists simply of enabling the stock mod_dav module.

1)在Web服务器上启用DAV扩展。这仅包括启用库存mod_dav模块。

2) Use any DAV-based file manager. Heck, there's one even for Android: https://play.google.com/store/apps/details?id=jp.ddo.shigadroid.webdavfilemanager&hl=en

2)使用任何基于DAV的文件管理器。哎呀,甚至还有Android版:https://play.google.com/store/apps/details?id = jp.ddo.shigadroid.webdavfilemanager&hl = en

For native Linux, you don't need any special client software. A brief googling around suggests that current Gnome and KDE desktops can natively access remote files via the DAV protocol. Here's a random page Google came up with, with examples: http://doc.owncloud.org/server/6.0/user_manual/files/files.html

对于本机Linux,您不需要任何特殊的客户端软件。一个简短的谷歌搜索表明,当前的Gnome和KDE桌面可以通过DAV协议本地访问远程文件。这是Google提出的一个随机页面,其中包含示例:http://doc.owncloud.org/server/6.0/user_manual/files/files.html

I'm sure there are plenty of standalone DAV clients, that you can use to browse your web server via the DAV protocol, you can Google them up yourself.

我确信有很多独立的DAV客户端,您可以使用它们通过DAV协议浏览您的Web服务器,您可以自己谷歌它们。

Of course, there are some issues to work out here, regarding configuration, security, and permissions. You need to set aside some time to dig through mod_dav's documentation, and figure out exactly how you need your security setup to work.

当然,这里有一些问题需要解决,包括配置,安全性和权限。您需要留出一些时间来深入了解mod_dav的文档,并确切了解您需要安全设置如何工作。

#2


1  

A couple at things that could be doing that:

一对夫妇可能会这样做:

1) Check folder permissions

1)检查文件夹权限

2) Clear your browser cache and reload page

2)清除浏览器缓存并重新加载页面

3) And configurations from the documentation:

3)文档中的配置:

'uploadDir' => "",

This setting is used when KCFinder can't automatically detect its local filesystem path to the folder specified in uploadURL setting. Change this setting when KCFinder can't fetch the local filesystem path automatically.

当KCFinder无法自动检测其在uploadURL设置中指定的文件夹的本地文件系统路径时,将使用此设置。当KCFinder无法自动获取本地文件系统路径时,请更改此设置。

'dirPerms' => 0755,
'filePerms' => 0644,

Default filesystem permissions for new files and directories created with KCFinder. Windows servers will skip these settings.

使用KCFinder创建的新文件和目录的默认文件系统权限。 Windows服务器将跳过这些设置。

More Information in: http://kcfinder.sunhater.com/install

更多信息请访问:http://kcfinder.sunhater.com/install