To document a class method (function inside a class) in ImpressCMS, use the following template -

* Method description
* Long description of the method
* @param (optional, if the method accepts parameters, use a separate tag for each parameter
* @return what the method returns

Here is an example from class/icms.htmlpurifier.php -

Allows HTML Purifier library to be called when required
  • @param string $html input to be cleaned
    * @param string $config custom filtering config?
    * @param string $icms_PurifyConfig instanciate HTMLPurifier Library with default settings
    * @return string
    function icms_html_purifier($html, $config = 'system-global')

For information about other code elements, see Documenting Code Elements Category: Getting Started Category: Development Category: Documentation

Last modified on 2010/11/25 by Anonymous
The comments are owned by the poster. We aren't responsible for their content.