smarty-view-renderer Allows you to use Smarty templates in Yii

  1. Change Log
  2. 1.0.1 (available from github)
  3. 1.0.0
  4. 0.9.9
  5. 0.9.8
  6. 0.9.7
  7. 0.9.6
  8. 0.9.5
  9. 0.9

Note: Latest release and documentation are available at extension github page.

This extension allows you to use Smarty version 2 or 3 templates in Yii.

Resources
Requirements
  • Yii 1.0 or above
Installation
  • Extract the release file under protected/extensions.
  • Download and extract libs folder contents of Smarty package under protected/vendors/Smarty.
  • Add the following to your config file 'components' section:
'viewRenderer'=>array(
  'class'=>'application.extensions.yiiext.renderers.smarty.ESmartyViewRenderer',
    'fileExtension' => '.tpl',
    //'pluginsDir' => 'application.smartyPlugins',
    //'configDir' => 'application.smartyConfig',
),
Usage
  • Smarty documentation.
  • Current controller properties are accessible via {$this->pageTitle}.
  • Yii properties are available as follows: {$Yii->theme->baseUrl}.
  • Used memory is stored in {$MEMORY}, used time is in {$TIME}.

Change Log

1.0.1 (available from github)

  • Smarty 3.1 compatibility (Sam Dark)

1.0.0

  • changed autoload handling to work also when Yii autoloader has been modified (cebe)
  • ensure Smarty does not use SMARTY_SPL_AUTOLOAD (cebe)

0.9.9

  • Added possiblity to configure smarty properties (CAUTION: behavior of $filePermission changed) (cebe)
  • Fixed issue with rendering Widgets within a template (cebe)

0.9.8

  • Fixed renderFile method (Sam Dark)
  • Fixed bug with autoload Smarty 3 files in *nix (maksimgrib)

0.9.7

  • Code cleanup and minor fixes.

0.9.6

  • Changed translation category to 'yiiext'.
  • New naming conventions.
  • readme_ru.
  • Added $Yii variable.

0.9.5

  • YiiExt naming conventions changed, see readme.
  • Smarty 3 comatibility.
  • t and link plugin functions.

0.9

  • Initial public release (Sam Dark)
11 0
17 followers
1 840 downloads
Yii Version: 1.1
License: BSD-2-Clause
Category: Others
Developed by: samdark
Created on: Oct 11, 2009
Last updated: 10 years ago

Related Extensions