PHP code example of nitroxy / php-forms

1. Go to this page and download the library: Download nitroxy/php-forms library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

nitroxy / php-forms example snippets

html
Form::from_object($user, function($f){
  $f->text_field('name', 'Name');
  $f->text_field('age', 'Age', ['type' => 'number', 'min' => 1]);
  $f->select(FormSelect::from_array($f, 'role', array('', 'Manager', 'Frobnicator', 'Developer'), 'Role'));
  $f->textarea('description', 'Description');
}, ['action' => $user->url, 'method' => 'patch']);