Warning: include(../../script/pdocrud.php): Failed to open stream: No such file or directory in /var/sentora/hostdata/digjainwi/public_html/allsanginfodev/demo/pages/password-encryption.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/password-encryption.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/password-encryption.php on line 1
PDOCrud - CRUD application generator for PHP and Mysql, Pgsql and Sqlite database.

Password Encryption Define password encryption method (Added in v 3.6)

You can define the encryption method to be used for password type fields before data insert or select. Previously you need to add callback function for this feature but now you can achieve same using this function also. Supported methods are base64_encode, md5 and sha1 with no extra parameters. If you need other way to encrypt, you can use the callback function.

  
                                $pdocrud = new PDOCrud();
                                $pdocrud->formFields(array("user_name","password"));
                                 /**
                                * Sets the type of field
                                * @param   string  $fieldName                             field name for types needs to be set
                                * @param   string  $type                                  Field type 
                                * @param   string  $parameters                            Field parameters
                                * return   object                                         Object of class
                                */
                                $pdocrud->fieldTypes("password", "password", array("encryption"=>"md5"));
                                echo $pdocrud->dbTable("users")->render("insertform");
                            

password encryption using PDOCrud


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