PHPackages                             corbinjurgens/qform - 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. corbinjurgens/qform

ActiveLibrary

corbinjurgens/qform
===================

Quickly create inputs. Made for Bootstrap 4 but you can alter the template

v2.1.0(4y ago)022MITPHP

Since Apr 18Pushed 4y ago1 watchersCompare

[ Source](https://github.com/corbinjurgens/qform)[ Packagist](https://packagist.org/packages/corbinjurgens/qform)[ RSS](/packages/corbinjurgens-qform/feed)WikiDiscussions master Synced yesterday

READMEChangelog (10)Dependencies (1)Versions (14)Used By (0)

Introduction
============

[](#introduction)

Confirmed working on Laravel 7.0.0, 8.0.0 and 8.73.2 projects

Created for personal use, feel free to use / extend

QForm for Laravel does a bunch of html form stuff, making use of Laravel components

- Create most types of html inputs with a single component
- Automatically get old() values and errors
- Make use of the additional functions to automatically prefix your input form name attributes
- Customizable templates
- In the provided base Bootstrap 4 template, it makes some attempts to provide labelling, error and other accesibility features.

```

```

- The input will automatically look for errors and old values based on value given by name
- The input will look to array or model given by @QFormData() or directly from the "data" attribute to get input value

Warnings
--------

[](#warnings)

For select and other variable input types, strict comparison is used. If your input value is an integer, and is declared as an integer in the variables array, you will need to set the "int" attribute so that it will be cast as an integer before comparison

Setup
=====

[](#setup)

Composer
--------

[](#composer)

composer require corbinjurgens/qform

Manual Installation
-------------------

[](#manual-installation)

Copy the following to main composer.(in the case that the package is added to packages/corbinjurgens/qform)

```
 "autoload": {
	"psr-4": {
		"Corbinjurgens\\QForm\\": "packages/corbinjurgens/qform/src"
	},
},

```

and run

```
composer dump-autoload

```

Add the following to config/app.php providers

```
Corbinjurgens\QForm\ServiceProvider::class,

```

Add alias to config/app.php alias

```
"QForm" => Corbinjurgens\QForm\Facade::class,

```

Basic Usage
===========

[](#basic-usage)

Directly
--------

[](#directly)

Using components as is, and benefit purely from the template taking care of the html and css

Simple inputs

```

// $value = 'This is text';

// $value = True; In this case the checkbox value will always be 1, and only be checked if value is true

```

Array input, ie. anything that has multiple options

You should be sure to set the int attribute if your variable keys are integer, so that the value can be compared correctly

```
// $value = 1;
// $variables = [1 => 'Option 1', 2 => 'Option 2', 3 => 'Option 3'];

// $value = 'option1';
// $variables = ['option1' => 'Option 1', 'option2' => 'Option 2', 'option3' => 'Option 3'];

// $value = [1, 2, 3]; If a checkbox has an array given for :variables, it will behave differently and expect :value to also be array
// $variables = [1 => 'Option 1', 2 => 'Option 2', 3 => 'Option 3'];

```

Smartly
-------

[](#smartly)

Using components with the QForm tools is the intended usage of this package

In your template set the target model or array. All inputs after this will use this data to retrieve values

```
@QFormData(['test' => '1', 'test2' => 2])

{{-- The component parses the name property, and gets the 'test' column from the data --}}

{{-- If the required data column differs from the name, you can specifify it with 'column' --}}

```

You can also set data directly for each input

```

```

Bonus
-----

[](#bonus)

You can create an input using a blade function

```
@QFormInput(['type' => 'text', 'name' => 'country', 'data' => $user])
```

Is the alternative method to

```

```

Other functions
---------------

[](#other-functions)

Use the prefix function and pass an array (or null to clear), and it will automatically prefix the inputs name attribute

```
@QFormData($user)

@QFormPrefix(['admin', 'data'])

{{-- the inputs name attribute will be name="admin[data][level]"  --}}
```

You can also use prefixIn() and prefixOut() to add a set of prefixes, and then after back out again. QForm::prefixReset() or @QFormPrefix with no parameter can be used to clear the prefix setting completely.

```
@QFormPrefixIn(['admin', 'data'])

{{-- name will be name="admin[data][name]" --}}

{{-- name will be name="admin[data][address]" as prefix is retained between inputs--}}

@QFormPrefixIn(['preferences'])

{{-- name will be name="admin[data][preferences][email]" --}}

@QFormPrefixOut()

{{-- name will be name="admin[data][dob]" so we have gone back to the previous prefix config --}}
```

Customize template
==================

[](#customize-template)

Publish views via

```
php artisan vendor:publish --tag="qform-views"

```

You can edit the files directly, or the component templates "x-qform-input", "x-qform-error" and "x-qform-submit" support taking a suffix.

Make a copy of the template, and add suffix for example `input.blade.php` becomes `input_bootstrap3.blade.php`, then you can set the suffix "bootstrap3" directly on the component like &lt;x-qform-input template="bootstrap3" .../&gt;, or globally via `QForm::setGlobalTemplate('bootstrap3')` or @QFormTemplate('bootstrap3')

Other stuff
===========

[](#other-stuff)

You can quickly create forms with the ` ` component. method will default to POST and also provide @csrf and @method when necessary

A bunch of features aren't documented here

Notes
=====

[](#notes)

This code is not thoroughly and not to any standard. Provided as is.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

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

Every ~27 days

Recently: every ~1 days

Total

12

Last Release

1547d ago

Major Versions

v0.0.1-alpha → v1.0.0-alpha32021-04-28

v1.x-dev → v2.0.0-alpha12022-02-08

### Community

Maintainers

![](https://www.gravatar.com/avatar/171ca92c9485e447aa4e83d138a01ccd433e377faf2c005fc74fbf036499a2b8?d=identicon)[corbinjurgens](/maintainers/corbinjurgens)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/corbinjurgens-qform/health.svg)

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

###  Alternatives

[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11320.2M21](/packages/anourvalar-eloquent-serialize)[namu/wirechat

A Laravel Livewire messaging app for teams with private chats and group conversations.

54324.5k](/packages/namu-wirechat)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135192.6k5](/packages/statamic-rad-pack-runway)

PHPackages © 2026

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