Monday, January 21, 2019

Difference between hook_boot and hook_init Drupal

hook_boot() hook_init()
hook_boot() will executes even on cached pages hook_init() will not executes on cached pages
hook_boot() is called before modules or most include files are loaded into memory (1.e., This hook will called while Drupal is still in bootstrap mode). hook_init(),is called After all modules are loaded into memory.
It happens while Drupal is still in bootstrap mode. It happens after bootstrap mode.

No comments:

Post a Comment

Difference between hook_boot and hook_init Drupal

hook_boot() hook_init() hook_boot() will executes even on cached pages hook_init() will not executes on cached pages hook_boot() is ...