class UrlModel extends PermissionModel

A Model that has a URL

Methods

static string
getRouteName(string $action = 'show')

Get the name of the route that shows the object

static string
getParamName()

Get the name of the object's parameter in the route

static string
getTypeForHumans()

Gets a human-readable format of the model's type

string
getURL(string $action = 'show', bool $absolute = false, array $params = array(), boolean $vanity = false)

Get an object's url

string
getPermaLink(string $action = 'show', bool $absolute = false, array $params = array())

Get an object's permanent url

Details

at line line 20
static string getRouteName(string $action = 'show')

Get the name of the route that shows the object

Parameters

string $action The route's suffix

Return Value

string

at line line 29
static string getParamName()

Get the name of the object's parameter in the route

Return Value

string

at line line 38
static string getTypeForHumans()

Gets a human-readable format of the model's type

Return Value

string

at line line 53
string getURL(string $action = 'show', bool $absolute = false, array $params = array(), boolean $vanity = false)

Get an object's url

Parameters

string $action The action to perform (e.g show, list or delete)
bool $absolute Whether to return an absolute URL
array $params Extra parameters to pass to the URL generator
boolean $vanity Whether to force the URL to contain just the alias

Return Value

string A link

Get an object's permanent url

Parameters

string $action The action to perform (e.g show, list or delete)
bool $absolute Whether to return an absolute URL
array $params Extra parameters to pass to the URL generator

Return Value

string A permanent link