PHPackages                             tltemplates/txtfile - 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. tltemplates/txtfile

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

tltemplates/txtfile
===================

A class to help read and write file to txt file faster

1.1.2(5y ago)110MITPHPPHP ^5.2 | ^7.2

Since Oct 6Pushed 5y ago1 watchersCompare

[ Source](https://github.com/androideen/txtfile)[ Packagist](https://packagist.org/packages/tltemplates/txtfile)[ Docs](https://www.tldevtech.com/txtfile)[ RSS](/packages/tltemplates-txtfile/feed)WikiDiscussions master Synced today

READMEChangelog (3)DependenciesVersions (5)Used By (0)

TxtFile
=======

[](#txtfile)

A small PHP library to help read and write data to text file

Usage
-----

[](#usage)

Create class to handle a file

```
//access the file
$file = new TxtFile('text.txt');
//access the file and create if it does not exist
$file = new TxtFile('text.txt', true);

```

Read content of the file

```
//store result in an array
$array = $file->readAllAsArray();
//store result in a string
$content = $file->readAllAsString();

```

Read more on [TL Dev Tech](https://www.tldevtech.com/txtfile/)

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity52

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.

###  Release Activity

Cadence

Every ~57 days

Total

4

Last Release

1869d ago

PHP version history (2 changes)v1.0PHP ^5.2

1.1PHP ^5.2 | ^7.2

### Community

Maintainers

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

---

Top Contributors

[![androideen](https://avatars.githubusercontent.com/u/22142051?v=4)](https://github.com/androideen "androideen (15 commits)")

---

Tags

filetexttxt

### Embed Badge

![Health badge](/badges/tltemplates-txtfile/health.svg)

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

###  Alternatives

[league/flysystem

File storage abstraction for PHP

13.6k639.1M2.1k](/packages/league-flysystem)[league/flysystem-aws-s3-v3

AWS S3 filesystem adapter for Flysystem.

1.6k263.6M787](/packages/league-flysystem-aws-s3-v3)[knplabs/gaufrette

PHP library that provides a filesystem abstraction layer

2.5k39.8M123](/packages/knplabs-gaufrette)[knplabs/knp-gaufrette-bundle

Allows to easily use the Gaufrette library in a Symfony project

72528.6M91](/packages/knplabs-knp-gaufrette-bundle)[league/flysystem-local

Local filesystem adapter for Flysystem.

226231.8M39](/packages/league-flysystem-local)[league/flysystem-memory

In-memory filesystem adapter for Flysystem.

8533.6M194](/packages/league-flysystem-memory)

PHPackages © 2026

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