PHPackages                             newclass/forma - 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. newclass/forma

ActiveLibrary

newclass/forma
==============

The PHP form generator.

v1.0.0(9y ago)037MITPHPPHP &gt;=5.5.0

Since Dec 4Pushed 8y agoCompare

[ Source](https://github.com/newclass-pl/forma)[ Packagist](https://packagist.org/packages/newclass/forma)[ RSS](/packages/newclass-forma/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

README
======

[](#readme)

[![license](https://camo.githubusercontent.com/4a018965bd8c82cecfad8d9c844dcefc678a887eab90cb8965f025467d3da080/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f626166732f7669612e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/4a018965bd8c82cecfad8d9c844dcefc678a887eab90cb8965f025467d3da080/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f626166732f7669612e7376673f7374796c653d666c61742d737175617265)[![PHP 5.5+](https://camo.githubusercontent.com/aa78f147c236f46697a4bd15778f6b31f453b360ebaa19b21c549b3b40721911/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d352e352b2d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/aa78f147c236f46697a4bd15778f6b31f453b360ebaa19b21c549b3b40721911/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d352e352b2d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)

What is Forma?
--------------

[](#what-is-forma)

Forma is a PHP form manager. Support for base html tag:

- textarea
- date
- text
- file
- number
- password
- email
- checkbox
- select

Auto validate data and render HTML template.

Auto match data from HTTP request.

Installation
------------

[](#installation)

The best way to install is to use the composer by command:

composer require newclass/forma

composer install

Use example

```
use Forma\Field\CheckboxField;
use Forma\Field\NumberField;
use Forma\FormBuilder;
use Forma\Request;

$builder = new FormBuilder();
$request = new RequestImpl(); //your http request class

$builder->setRequest($request);

//add checkbox field
$builder->addField(new CheckboxField([
    'label' => 'Checkbox label',
    'name' => 'checkbox',
]));

//add number field
$builder->addField(new NumberField([
    'label' => 'Number label',
    'name' => 'number',
]));

//set default data for number field
$builder->setData([
    'number' => 20,
]);

//confirm data
$builder->submit();

$valid=$builder->isValid(); //return true or false. If invalid then execute $builder->getErrors() to get error messages.

if(!$valid){
    echo $builder->render(); //show form when invoke errors or not confirmed
}

//get data from request and default field config
$data = $builder->getData();

var_dump($data);

```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity59

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

Unknown

Total

1

Last Release

3449d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4acb0470eeb89d512ba7302a6184b091c03a433695340e6a4e87e75fe87bdbc6?d=identicon)[newclass-pl](/maintainers/newclass-pl)

---

Top Contributors

[![michaljantomczak](https://avatars.githubusercontent.com/u/24293672?v=4)](https://github.com/michaljantomczak "michaljantomczak (6 commits)")

### Embed Badge

![Health badge](/badges/newclass-forma/health.svg)

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

PHPackages © 2026

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