PHPackages                             hiokwee/filemanager - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. hiokwee/filemanager

ActiveLibrary[File &amp; Storage](/categories/file-storage)

hiokwee/filemanager
===================

017PHP

Since Jun 18Pushed 9y ago1 watchersCompare

[ Source](https://github.com/hiokwee/Filemanager)[ Packagist](https://packagist.org/packages/hiokwee/filemanager)[ RSS](/packages/hiokwee-filemanager/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Filemanager
===========

[](#filemanager)

> ### methods
>
> [](#methods)

1. **File (string $\_target\_dir)**
    *$\_target\_dir* The target directory where the files will be saved
2. **upload (string $param\_name) : boolean**
    *$param\_name* The HTML form input field name
3. **delFileByName (string $name) : boolean**
    *$name* Name of the file
4. **getFileByName (string $name) : boolean**
    *$name* Name of the file
5. **getFileList () : string**
6. **getTargetFolder () : string**
7. **setAllowedExtensions (array&lt;mixed,string&gt; $extensions)**
    *$extensions* The permitted extension types
8. **setOnlyAllowImage (boolean $image\_only)**
    *$image\_only* Permit only image file types
9. **setMaxFileSize (integer $max\_file\_size)**
    *$max\_file\_size* Maximum permitted file size in bytes
10. **setScanFile (boolean $scan\_file)**
    *$scan\_file* Enable anti-virus file scan

> ### example
>
> [](#example)

```
$fm = new File("uploads/");
$fm->setAllowedExtensions(["PNG", "GIF", "TXT"]);
$fm->setOnlyAllowImage(true);
$fm->setMaxFileSize(5120);
$fm->setScanFile(true);

if (isset($_POST["act"])) {

        // upload file
        if ($_POST["act"] === "upload") {
                try {
                        $fm->upload("fileToUpload");
                }
                catch (Exception $e) {
                }
        }

        // download file by name
        elseif ($_POST["act"] === "download") {
                if (isset($_POST["filename"])) {
                        try {
                                $fm->getFileByName($_POST["filename"]);
                        }
                        catch (Exception $e) {
                        }
                }
        }

        // delete file by name
        elseif ($_POST["act"] === "delete") {
                if (isset($_POST["filename"])) {
                        try {
                                $fm->delFileByName($_POST["filename"]);
                        }
                        catch (Exception $e) {
                        }
                }
        }
}
```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/5964292?v=4)[hiokwee](/maintainers/hiokwee)[@hiokwee](https://github.com/hiokwee)

---

Top Contributors

[![hiokwee](https://avatars.githubusercontent.com/u/5964292?v=4)](https://github.com/hiokwee "hiokwee (23 commits)")

### Embed Badge

![Health badge](/badges/hiokwee-filemanager/health.svg)

```
[![Health](https://phpackages.com/badges/hiokwee-filemanager/health.svg)](https://phpackages.com/packages/hiokwee-filemanager)
```

###  Alternatives

[venveo/craft-compress

Create smart zip files from Craft assets on the fly

124.7k](/packages/venveo-craft-compress)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
