Note: You are currently viewing documentation for Moodle 2.3. Up-to-date documentation for the latest stable version is available here: Customlabel subtype development framework.

Customlabel subtype development framework

From MoodleDocs
Revision as of 18:34, 14 December 2012 by Valery Fremaux 2 (talk | contribs) (Created page with "The customlabel subtype development framework is a set of writting and development rules which will make easy making new subtypes for use in course contents. The customlabel con...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The customlabel subtype development framework is a set of writting and development rules which will make easy making new subtypes for use in course contents.

The customlabel concept is to centralize all mechanical aspects in the customlabel module, thus keeping writing of a subtype minimalist.

What is a subtype?

A subtype is a cutomlabel subplugin handled by the generic subplugin API of Moodle.

A subtype is essentially :

  • a directory in the mod/customlabel/type directory
  • a subclass of the customlabel_type (@see /mod/customlabel/type/customtype.class.php)
  • a file version.php to handle subplugin verisonning
  • a lang directory for storing templates and language dependant strings
  • a local css file for preseting default styling

The customlabel_type class

The customlabel_type class describes what is the internal information model of the customlabel.