RouteHelper

Route Helper

A class providing basic routing for urls that are for content types found in the #__content_types table and rows found in the #__ucm_content table.

since

3.1

package

Joomla CMS

Methods

findItem

Method to find the item in the menu structure

findItem(mixed||string|int needles = []) : 
since

3.1

Arguments

needles

array<string|int, mixed>Array of lookup values

Response

mixed

getCategoryRoute

Fetches the category route

getCategoryRoute( catid,  language,  extension = '') : 
static
since

3.2

throws

InvalidArgumentException

Arguments

catid

mixedCategory ID or CategoryNode instance

language

mixedLanguage code

extension

stringExtension to lookup

Response

string

getRoute

A method to get the route for a specific item

getRoute( id,  typealias,  link = '',  language = null,  catid = null) : 
since

3.1

Arguments

id

intValue of the primary key for the item in its content table

typealias

stringThe type_alias for the item being routed. Of the form extension.view.

link

stringThe link to be routed

language

stringThe language of the content for multilingual sites

catid

intOptional category id

Response

stringThe route of the item

lookupItem

Static alias to findItem() used to find the item in the menu structure

lookupItem(mixed||string|int needles = []) : 
static
since

3.2

Arguments

needles

array<string|int, mixed>Array of lookup values

Response

mixed

Properties

lookup

Holds the reverse lookup

static
since

3.1

Type(s)

array<string|int, mixed>

extension

Option for the extension (such as com_content)

since

3.1

Type(s)

string

id

Value of the primary key in the content type table

since

3.1

Type(s)

string

view

Name of the view for the url

since

3.1

Type(s)

string