Class CPradoViewRenderer
CPradoViewRenderer implements a view renderer that allows users to use a template syntax similar to PRADO templates.
To use CPradoViewRenderer, configure it as an application component named "viewRenderer" in the application configuration:
array( 'components'=>array( ...... 'viewRenderer'=>array( 'class'=>'CPradoViewRenderer', ), ), )
CPradoViewRenderer allows you to write view files with the following syntax:
// PHP tags: <%= expression %> // <?php echo expression ?> <% statement %> // <?php statement ?></li> // component tags: <com:WigetClass name1="value1" name2='value2' name3={value3} > // <?php $this->beginWidget('WigetClass', // array('name1'=>"value1", 'name2'=>'value2', 'name3'=>value3)); ?> </com:WigetClass > // <?php $this->endWidget('WigetClass'); ?> <com:WigetClass name1="value1" name2='value2' name3={value3} /> // <?php $this->widget('WigetClass', // array('name1'=>"value1", 'name2'=>'value2', 'name3'=>value3)); ?> // cache tags: <cache:fragmentID name1="value1" name2='value2' name3={value3} > // <?php if($this->beginCache('fragmentID', // array('name1'=>"value1", 'name2'=>'value2', 'name3'=>value3))): ?> </cache:fragmentID > // <?php $this->endCache('fragmentID'); endif; ?> // clip tags: <clip:clipID > // <?php $this->beginClip('clipID'); ?> </clip:clipID > // <?php $this->endClip('clipID'); ?> // comment tags: <!--- comments ---> // the whole tag will be stripped off
- CComponent
- CApplicationComponent implements IApplicationComponent
- CViewRenderer implements IViewRenderer
- CPradoViewRenderer
Package: system\web\renderers
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Steve Heyns http://customgothic.com/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 1.0
Located at x2engine/framework/web/renderers/CPradoViewRenderer.php
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Steve Heyns http://customgothic.com/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 1.0
Located at x2engine/framework/web/renderers/CPradoViewRenderer.php
protected
|
#
generateViewFile( string $sourceFile, string $viewFile )
Parses the source view file and saves the results as another file. This method is required by the parent class. |
getViewFile(),
renderFile()
|
getIsInitialized(),
init()
|
$fileExtension,
$filePermission,
$useRuntimePath
|
$behaviors
|
$isInitialized
|