Adding custom submit handler to form in Drupal 8

By default in a Drupal 8 form submitform($form, FormStateInterface $form_state) will handle the the submission of form values. However we can also add our own submit handlers easily with Drupal 8 form api. The below example explains that. Add the custom submit handler function with class name in the $form[‘#submit’] array   namespace Drupal\lnformcontrol\Form; use Continue Reading

Connect CakePHP app to the MySQL database

CakePHP is a popular PHP framework that is used to build web applications. It makes building web applications quicker, simpler and uses less coding. It offers a flexible database access layer. You can install CakePHP either by downloading their website or by using composer. composer self-update && composer create-project –prefer-dist cakephp/app cms After the installation Continue Reading