API16

API16:JRouter/getVar

From Joomla! Documentation

Description

Get a router variable



Syntax

getVar($key)
Parameter Name Default Value Description
$key The name of the variable

Returns

mixed Value of the variable

Defined in

libraries/joomla/application/router.php

Importing

jimport( 'joomla.application.router' );

Source Body

public function getVar($key)
{
        $result = null;
        if (isset($this->_vars[$key])) {
                $result = $this->_vars[$key];
        }
        return $result;
}



Examples

Code Examples