2. AGENDA:
• Drupal 8 Api Changes:
• Module info file
• Routing System
• Drupal 8 CMI & Using Config inspector
• Basic changes to oftenly uses Drupal functions.
• Writing forms and their submit handlers in d8
• Live Demo of Porting a Drupal 7 module to Drupal 8.
2
3. Info File
•Info files changed to info.yml
•Old info file: {d7.info}
•New info file: {d8.info.yml}
3
11. CONFIGURATION SCHEMA
•When would Config data get saved?
• UI changes (automatic): When the save button
is clicked on an admin page, data gets written to
the active store as well as db.
• Code changes (manual): use
admin/config/development/sync to sync the
config in code with db and active store.
1
14. WRITING FORMS AND THEIR SUBMIT
HANDLERS IN D8
•FormInterface(https://api.drupal.org/api/drupal/co
re!lib!Drupal!Core!Form!FormInterface.php/interfac
e/FormInterface/8)
•SystemConfigFormBase(http://drupalcontrib.org/
api/drupal/drupal!core!modules!system!lib!Drupal!sys
tem!SystemConfigFormBase.php/class/SystemC
onfigFormBase/8)
14
20. Basic Function from d7 to d8
• hook_init removed(https://drupal.org/node/2013014)
• Module/hook system functions replaced with module handler
service(https://drupal.org/node/1894902)
• drupal_goto has been removed(https://drupal.org/node/2023537)
• hook_boot has been removed(https://drupal.org/node/1909596)
• $_GET[‘q'] has been removed(https://drupal.org/node/1659562)
• For more goto https://drupal.org/list-changes
20