Download the PHP package lexal/laravel-stepped-form without Composer
On this page you can find all versions of the php package lexal/laravel-stepped-form. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download lexal/laravel-stepped-form
More information about lexal/laravel-stepped-form
Files in lexal/laravel-stepped-form
Package laravel-stepped-form
Short Description Stepped Form for Laravel & Lumen.
License MIT
Informations about the package laravel-stepped-form
Stepped Form for Laravel & Lumen
The package is based on the HTTP Stepped Form and built for Laravel & Lumen frameworks.
Table of Contents
- Requirements
- Installation
- Configuration
- Publish the config
- Available config options
- Usage
- License
Requirements
PHP: >=8.1
Laravel: ^9.0 || ^10.0
Installation
Via Composer
Additional changes for Lumen framework
Add the following snippet to the bootstrap/app.php
file under the providers section as follows:
Configuration
Publish the config
Run the following command to publish the package config file:
Available config options
The configuration file config/stepped-form.php
has the following options:
renderer
- contains Renderer class, instance or service alias that will translate step's template definition to the response. Must implement RendererInterface;redirector
- contains Redirector class, instance or service alias that will redirect user between different steps. Must implement RedirectorInterface;entity_copy
- contains Entity Copy class, instance or service alias that will clone entity of the given step. Must implement EntityCopyInterface;event_dispatcher
- contains Event Dispatcher class, instance or service alias that will dispatch form events. Must implement EventDispatcherInterface;exception_normalizers
- contains exception normalizers that the form will use to normalize SteppedFormException into the Response instance. Read more about them in the HTTP Stepped Form docs;forms
- contains array of all application forms definitions. Form definition must have builder class for dynamic forms or array of steps for the static forms, settings class and storage where the form will store data.
Usage
- Publish configuration file.
- Replace with custom implementation of redirector, renderer and entity copy if necessary. Add custom exception normalizers if necessary.
-
Declare your form settings.
-
Add forms definitions.
-
Static form
- Dynamic form
-
-
Use Stepped Form in you controller. Stepped Form will have service alias as "stepped-form." + form key form configuration.
ServiceProvider.php
CustomerController.php
See configuration file for more information.
License
Laravel & Lumen Stepped Form is licensed under the MIT License. See LICENSE for the full license text.
All versions of laravel-stepped-form with dependencies
illuminate/contracts Version ^10.0 || ^11.0 || ^12.0
illuminate/routing Version ^10.0 || ^11.0 || ^12.0
illuminate/support Version ^10.0 || ^11.0 || ^12.0
lexal/http-stepped-form Version ^3.0