PHPackages                             tasoft/php-string-parser - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. tasoft/php-string-parser

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

tasoft/php-string-parser
========================

v0.9.8(3y ago)02293MITPHPPHP ^7|^8CI failing

Since Apr 23Pushed 3y agoCompare

[ Source](https://github.com/tasoftch/php-string-parser)[ Packagist](https://packagist.org/packages/tasoft/php-string-parser)[ RSS](/packages/tasoft-php-string-parser/feed)WikiDiscussions master Synced 5d ago

READMEChangelog (2)Dependencies (1)Versions (3)Used By (3)

PHP String Parser
=================

[](#php-string-parser)

My php string parser library provides an abstract mechanism to tokenize, parse and until compile any kind of scripts you want.
There are some implemented parsers ready to use for expressions.

```
$parser = new SimpleTokenParser();
print_r($parser->parseString("12 + 13 / 6"));
```

This list all parsed tokens.
Token parsing is done by php token\_get\_all function, but you can easy subclass a tokenizer to customize string tokenizing.

Install
-------

[](#install)

PHP String Parser is a composer package. So you can simply install it by

```
$ composer require tasoft/php-string-parser

```

Now the library is available under namespace \\TASoft\\Parser...

### Examples

[](#examples)

The package tasoft/predicate uses this parser to create predicates from string.

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity47

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 ~1020 days

Total

2

Last Release

1194d ago

PHP version history (2 changes)v0.9.5PHP ^7.2

v0.9.8PHP ^7|^8

### Community

Maintainers

![](https://www.gravatar.com/avatar/c7b1a2883faeab6f2b9558df70ce847c9e7dc3467a64db4f694e0716e842e9f2?d=identicon)[tasoft](/maintainers/tasoft)

---

Top Contributors

[![tasoftch](https://avatars.githubusercontent.com/u/24875322?v=4)](https://github.com/tasoftch "tasoftch (35 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/tasoft-php-string-parser/health.svg)

```
[![Health](https://phpackages.com/badges/tasoft-php-string-parser/health.svg)](https://phpackages.com/packages/tasoft-php-string-parser)
```

###  Alternatives

[mtdowling/jmespath.php

Declaratively specify how to extract elements from a JSON document

2.0k472.8M135](/packages/mtdowling-jmespathphp)[opis/closure

A library that can be used to serialize closures (anonymous functions) and arbitrary data.

2.6k230.0M284](/packages/opis-closure)[masterminds/html5

An HTML5 parser and serializer.

1.8k242.8M229](/packages/masterminds-html5)[sabberworm/php-css-parser

Parser for CSS Files written in PHP

1.8k191.2M65](/packages/sabberworm-php-css-parser)[michelf/php-markdown

PHP Markdown

3.5k52.4M345](/packages/michelf-php-markdown)[jms/metadata

Class/method/property metadata management in PHP

1.8k152.8M88](/packages/jms-metadata)

PHPackages © 2026

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