Ir al contenido
Docs

Referencia de clases y funciones

Template

Lista de métodos públicos de la clase Zittme\Framework\Template. Este documento se generó automáticamente a partir del código fuente del núcleo de Zittme.

Fuente: common/framework/Template.php

Métodos públicos

  • static function getInstance()
  • Provided for compatibility with old TemplateHandler.
  • function __construct(?string $dirname = null, ?string $filename = null, ?string $extension = null)
  • You can also call the constructor directly.
  • function setCachePath(?string $cache_path = null)
  • Set the path for the cache file.
  • function disableCache()
  • Disable caching.
  • function exists()
  • Check if the template file exists.
  • function getParent()
  • Get the parent template.
  • function setParent(self $parent)
  • Set the parent template.
  • function getVars()
  • Get vars.
  • function setVars($vars)
  • Set vars.
  • function addVars($vars)
  • Add vars.
  • function compile(?string $dirname = null, ?string $filename = null, ?string $override_filename = null)
  • Compile and execute a template file.
  • function compileDirect(string $dirname, string $filename)
  • Compile a template and return the PHP code.
  • function parse(?string $content = null)
  • Convert template code to PHP using a version-specific parser.
  • function execute()
  • Execute the converted template and return the output.
  • function getFragment(string $name)
  • Get a fragment of the executed output.
  • function getStack(string $name)
  • Get the contents of a stack.
  • function isRelativePath(string $path)
  • Check if a path should be treated as relative to the path of the current template.
  • function convertPath(string $path, ?string $basepath = null)
  • Convert a relative path using the given basepath.
  • function normalizePath(string $path)
  • Normalize a path by removing extra slashes and parent directory references.