Template::displayBegin - jcobban/Genealogy GitHub Wiki
$template->displayBegin()
Up: class Template
This method is called after the raw template files, as identified by the constructor, and calls to $template->includeSub
which do not use the "after" option, have been assembled but before any of the updates, defined by calls to $template->set
or $tag->update
, are applied. When this method is called $this->page
contains the raw template string, $this->fields
is an associative array of all of the substitutions defined by calls to $this->set
, $this->tagUpdates
contains the accumulated substitutions defined by calls to $tag->update
, but $this->dom->length
is zero. Therefore if the implementation requires access to the DOM it must call $this->parseHTML()
.
If the value of 'TITLE' has not been defined the base implementation initializes it from the text contents of the first <h1> tag in the template.
Classes derived from Template usually override or extend this base functionality. For an example see FtTemplate::displayBegin
Next: $template->displayEnd()