示例#1
0
 /**
  * This function uses the Variables extension to provide navigation aids such as DPL_firstTitle, DPL_lastTitle, or DPL_findTitle.  These variables can be accessed as {{#var:DPL_firstTitle}} if Extension:Variables is installed.
  *
  * @access	public
  * @param	array	Array of scroll variables with the key as the variable name and the value as the value.  Non-arrays will be casted to arrays.
  * @return	void
  */
 private function defineScrollVariables($scrollVariables)
 {
     $scrollVariables = (array) $scrollVariables;
     foreach ($scrollVariables as $variable => $value) {
         Variables::setVar(['', '', $variable, $value]);
         if (defined('ExtVariables::VERSION')) {
             \ExtVariables::get($this->parser)->setVarValue($variable, $value);
         }
     }
 }