Gumbo_Template_Engine_Basic

Gumbo_Template_Engine
   |
   --Gumbo_Template_Engine_Basic

Basic Template Engine Class

This Engine will perform a simple string replacement with the template variables. The template file will hold references to the template. The references will be contained within left and right delimeters. A template reference will look like: {reference}

The left and right delimeters can be altered from the defaults. It's important that these values are accurate, for the replacement of the references will not work.

Author(s): Michael Luster <mluster79@yahoo.com>
License:New BSD License
Copyright:Copyright (c) 2007, iBayou, Michael Luster
Link:http://sourceforge.net/projects/phpgumbo
Version:0.0.1

Inherited Methods

Class Methods

public Gumbo_Template_Engine_Basic __construct ( [string $file] ) [line 52]

Constructor

Parameter(s):

  • (string) $file :: template file name

[ Top ]
public void assign ( string|array $key, [mixed $val] ) [line 98]

Assigns a template variable with a value

Parameter(s):

  • (string|array) $key :: template file reference
  • (mixed) $val :: (primitive type or Gumbo_Interface_Output)
  • precondition:  must be primitive type
  • throws:  Gumbo_Exception
Overrides
Gumbo_Template_Engine::assign()

[ Top ]
protected void parse ( ) [line 68]

Parses the template file into an HTML string

  • postcondition:  $this->isFormatted ()
  • precondition:  $this->setFormatted (false)
  • precondition:  $this->setHtml (null)
Overrides
Gumbo_Template_Engine::parse()

[ Top ]