Repository navigation
v0.1.0
First release of ephraitech/ci4-forms: a form builder for CodeIgniter 4.7+.
Define a form once in PHP and the package renders it with Bootstrap 5, validates it
with CodeIgniter's Validation service, repopulates input after errors, and returns
only clean data for the fields you defined.
Highlights
- Form classes (
define()) and inline forms (Form::make()) - 13 field types: text, email, password, number, tel, url, date, hidden, textarea,
select (with option groups), radio, checkbox, submit validate()from POST, GET or JSON requests;validated()returns only defined fields,
trimmed, with empty strings as null and unticked checkboxes as 0- Works with both re-rendering and
redirect()->withInput(), including manual errors
fromsetError() fill()for edit screens from arrays or Entities; PUT/PATCH/DELETE spoofing- Escaped, accessible Bootstrap 5 markup; custom layouts with
field()andcontrol() php spark forms:publishto customise the views
Requirements
PHP 8.2+ and CodeIgniter 4.7+.
See the README for full documentation.