Skip to content
Daniel Kvist edited this page Jun 16, 2013 · 3 revisions

Basic idea plugins

Build a global array with function pointers that are executed when the do/perfom functions are called in the core. The function pointers are added by plugins that are enabled. The execution points can be found here.

1. Recognition

  • Admin page that scans plugin folder looking for plugin-folders and some manifest file
  • Manifest contains name, version, plugin main file (perhaps more strict like drupal? force naming?)
  • Admin ui shows list of plugins (enabled/disable states)

2. Enable

  • Checkbox and save plugin main file in database (if more strict, plugin name only?)

3. Run

  • When core execution finishes, do_action() and do_filter()

Basic idea theming

1. Recognition

  • Admin page that scans theme folder looking for manifest file

  • Manifest contains info about name, type, version of theme

  • User themes can differ from admin themes

2. Enable

  • Store path to theme in database

3. Run

  • Fetch theme path from database
Clone this wiki locally