You are here

function Smarty::clear_assign in Quiz 6.6

Same name and namespace in other branches
  1. 6.5 includes/moodle/lib/smarty/Smarty.class.php \Smarty::clear_assign()

clear the given assigned template variable.

Parameters

string $tpl_var the template variable to clear:

File

includes/moodle/lib/smarty/Smarty.class.php, line 673

Class

Smarty
@package Smarty

Code

function clear_assign($tpl_var) {
  if (is_array($tpl_var)) {
    foreach ($tpl_var as $curr_var) {
      unset($this->_tpl_vars[$curr_var]);
    }
  }
  else {
    unset($this->_tpl_vars[$tpl_var]);
  }
}