Download the PHP package chanthoeun/filament-custom-forms without Composer

On this page you can find all versions of the php package chanthoeun/filament-custom-forms. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package filament-custom-forms

Filament Custom Forms

A powerful and simplified FilamentPHP plugin to manage and submit dynamic custom forms. Refactored for speed and ease of use in standalone environments.

Features

Requirements

Installation

1. Install via Composer

2. Publish Assets

3. Run Migrations

4. Register the Plugin

Add the plugin to your Filament Panel provider (app/Providers/Filament/AdminPanelProvider.php):

Note on Translations: If you enable ->translations(true), ensure you have defined your desired locales in config/filament-custom-forms.php under the locales key.

Step-by-Step Guide

Here is a detailed guide on how to build and use your first custom form from start to finish.

Step 1: Create a Global Field (Optional but Recommended)

Global fields are reusable fields you can use across many different forms (e.g., "Gender" or "Country").

  1. In your Filament admin panel, navigate to Form Builder > Global Fields.
  2. Click New Global Field.
  3. Name it "Gender", select the Type Select or Radio.
  4. Go to the Options & Choices tab, and enter the choices manually (e.g. male => Male, female => Female).
  5. Save the field.

Step 2: Create a Custom Form

  1. Navigate to Form Builder > Custom Forms.
  2. Click New Custom Form.
  3. Give it a name (e.g., "User Registration Survey") and toggle it to Active.
  4. Save to continue to the field builder.

Step 3: Add Fields to Your Form

Once the form is created, you will see a section at the bottom to add fields.

  1. Click Create Field to make a brand new field.
    • Set the Type to Text Input and name it first_name.
    • Check the Is Required toggle.
    • Save it.
  2. Click Import Global Field to use a pre-made field.
    • Select the "Gender" global field we made in Step 1. It will instantly attach itself to your form.
  3. You can reorder fields by dragging them up and down.

Step 4: Grouping with Layouts (Sections, Grids, Wizards)

Want to organize your form?

  1. Click Create Field and set the type to Section. Name it "Personal Details".
  2. Under the Layout & Display tab, set the Columns to 2. Save it.
  3. Edit your first_name and gender fields, and set their Parent Container to the "Personal Details" section.
  4. (Optional Wizard): If you create multiple Sections and toggle the Render as Wizard option on your main form settings, those sections will automatically become beautifully interactive Wizard Steps!

Step 5: Test and Submit Entries

  1. Navigate to Form Entry (usually automatically generated based on your form's name, e.g., "User Registration Survey Entries").
  2. Click New Entry.
  3. You will see the dynamic form you just built! Fill it out and click Save.
  4. Back on the list view, you can easily view, search, export to PDF/Excel, and manage all the submissions.

Form Configuration Options

When building a form, the plugin provides a powerful set of configurations for every field and layout block.

Default Values

Options & Choices (For Selects, Radios, Checkboxes)

Layout & Display

Field Specifics

Advanced Features

Multi-Language Support & Translations

This plugin natively supports spatie/laravel-translatable for robust multi-language forms:

  1. Form Labels & Names: The Form Name and all Field Labels are fully translatable. When a user creates a form, they can provide translated names and labels which will automatically render correctly based on the active locale.
  2. Submissions (Entries): Submitted data is saved securely and can be isolated by language.
  3. Translating Manual Choices: Form Configuration and Layout Options (such as Columns, Required, Unique Rules, and Manual Choices) are intentionally shared across languages to prevent admins from having to re-configure the entire layout for every language.
    • If you use "Manual Input" for Select, Radio, or Checkbox options and want them translated, simply enter your Laravel Translation Key (e.g., messages.gender_male) into the choice label field. The plugin automatically detects translation keys and applies Laravel's __() helper on the frontend. (If no translation file exists, it elegantly falls back to the exact text you typed).
    • Alternatively, use the Model or Enum Option Sources, which handle translations natively.

Dynamic Models & Enums

By default, to prevent exposing sensitive internal application classes to the form builder, Custom Forms requires you to explicitly opt-in which Models and Enums are allowed to be used as options for Select, Radio, and Checkbox fields.

To make a Model or Enum appear in the Custom Form Builder, simply implement the IsFormOption interface!

Using Enums

Using Models

Note: If you are using Translations and want your Enum labels to automatically adapt to the form's active language, the IsFormOption trait automatically handles the Laravel Application Locale swapping for you behind the scenes during resolution!

Maintenance

Updates

To update the package to the latest version, run:

If the update includes new migrations or changes to published assets, you may need to re-publish or run:

Versioning

This project follows Semantic Versioning. We use Git tags to manage releases.

To release a new version:

  1. Update CHANGELOG.md.
  2. Commit your changes.
  3. Tag the release: git tag v1.0.1.
  4. Push the tag: git push origin v1.0.1.

Changelog

Please see CHANGELOG for more information on what has changed recently.

License

The MIT License (MIT). Please see License File for more information.


All versions of filament-custom-forms with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
filament/filament Version ^4.0|^5.0
filament/schemas Version ^4.0|^5.0
lara-zeus/spatie-translatable Version ^1.0|^2.0
chanthoeun/filament-document-builder Version ^1.1
maatwebsite/excel Version ^3.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package chanthoeun/filament-custom-forms contains the following files

Loading the files please wait ...