PHPackages                             kholy/formbuilder - 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. kholy/formbuilder

ActiveLibrary

kholy/formbuilder
=================

Form Builder library for creating data oriented html bootstrap forms in Laravel

312Blade

Since Sep 26Pushed 4y ago2 watchersCompare

[ Source](https://github.com/AhmadAlkholy/Form-Builder-Laravel-Package)[ Packagist](https://packagist.org/packages/kholy/formbuilder)[ RSS](/packages/kholy-formbuilder/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Form Builder for Laravel
========================

[](#form-builder-for-laravel)

#### library for creating data oriented html forms

[](#library-for-creating-data-oriented-html-forms)

Usage:
------

[](#usage)

Simply in controller:

```
$form = FormBuilder::form(['action' => route('test'), 'method' => 'POST'])->make([
    ["type" => "text", "name" => "first_name", "label" => "First Name", "value" => "John"],
    ["type" => "text", "name" => "last_name", "value" => "Doe"]
]);
```

In view:

```

```

Attributes to add and their default values:
-------------------------------------------

[](#attributes-to-add-and-their-default-values)

AttributeExampleDescriptioinDefault Valuenamefirst\_namethe name attribute of the inputNo Default Valuetypetextareathe type of input you want it can have the usual values for html input tag (text, number, hidden ...) and it can also have the value of 'select' to create dropdown list or 'textarea' to create textarea elementtextvalueJohnit will be the default value of the fieldNo Default ValuelabelFirst NameThe name that will show to user above the fieldthe value of name attribute converted to title formatidfirst-namethe id attribute of the input fieldNo Default Valueclassfirst-namethe class attribute of the input fieldNo Default Valuecontainer\_classfirst-name-containerthe class attribute of the div that contains input fieldNo Default ValueplaceholderFirst Namethe placeholder attribute of the input fieldNo Default Valueoptions\["John Doe"\]the list of options for if you choose type to be 'select'No Default Valueattrsonchange="inputChanged"any custom attributes you want to add to the input fieldNo Default ValueerrorFirst Name is requiredthe error message to show the user if there's an errorNo Default Valuehtml`Click Me`html code to add if type attribute = raw\_htmlNo Default ValueYou can also use it with javascript like so:
--------------------------------------------

[](#you-can-also-use-it-with-javascript-like-so)

In controller:

```
$formBuilderJs = FormBuilder::js();
```

In blade file:

```

    {{ csrf_field() }}

    let data = [
        {name: "name", id: "name", placeholder: "Please enter your name"},
        {type: "textarea", name: "description", id: "desc", class: "desc", container_class: "descContainer"},
        {type: "select", name: "car", options: ['Ferrari', 'BMW'], value: "BMW"},
        {type: "radio", name: "city", options: [{name: 'New York', value: 'new_york'}, {name: 'London', value: 'london'}], value: "london"},
        {type: "raw_html", value: ""},
        {type: "file", name: "image"}
    ];

    const formBuilder = new FormBuilder(data, '#exampleForm');

```

You can find the details about how to use it in Javascript in [here](https://github.com/AhmadAlkholy/Form-Builder#readme)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity28

Early-stage or recently created project

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://www.gravatar.com/avatar/e3abe8b737d58827c3959d8214c7fbc0a7711b7f3ca8624b68023641fd274659?d=identicon)[Ahmad Alkholy](/maintainers/Ahmad%20Alkholy)

### Embed Badge

![Health badge](/badges/kholy-formbuilder/health.svg)

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

PHPackages © 2026

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