Warning: include(../../script/pdocrud.php): Failed to open stream: No such file or directory in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/field-not-required.php on line 1

Warning: include(../../script/pdocrud.php): Failed to open stream: No such file or directory in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/field-not-required.php on line 1

Warning: include(): Failed opening '../../script/pdocrud.php' for inclusion (include_path='.:/opt/remi/php81/root/usr/share/pear:/opt/remi/php81/root/usr/share/php:/usr/share/pear:/usr/share/php') in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/field-not-required.php on line 1
PDOCrud - CRUD application generator for PHP and Mysql, Pgsql and Sqlite database.

Field not required Set directly not required fields (updated in v 4.3)

By default, all fields are required fields, You can set fields not required using the fieldNotMandatory() function. Also, you can set all fields not required using the settings also

For Mysql database, fields with the default database values can be set whether they are required or not using the config["defaultValueFieldRequired"] = true; This will remove the required validation from the fields with default database value.

  
                            $pdocrud = new PDOCrud();
                            $pdocrud->fieldNotMandatory("phone");
                            echo $pdocrud->dbTable("users")->render("insertform");
                            

Field not mandatory using PDOCrud


Fatal error: Uncaught Error: Class "PDOCrud" not found in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/field-not-required.php:55 Stack trace: #0 {main} thrown in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/field-not-required.php on line 55