Yaf_View_Simple::clear

(Yaf >=2.2.0)
Clear Assigned values
public bool Yaf_View_Simple::clear ([ string $name ] )

clear assigned variable

Parameters:
name

assigned variable name

if empty, will clear all assigned variables

Returns:
Examples:
Yaf_View_Simple::clear() example
<?php
class IndexController extends Yaf_Controller_Abstract {
    public function indexAction() {
        $this->getView()->clear("foo")->clear("bar"); // clear "foo" and "bar"
        $this->_view->clear(); //clear all assigned variables
    }
?>

See also:

Yaf_View_Simple::assignRef() -

Yaf_View_Interface::assign() -

Yaf_View_Simple::__set() -

doc_php
2016-02-24 16:07:31
Comments
Leave a Comment

Please login to continue.