1 path.inc _path_get_schema_alias_maxlength()

Fetch the maximum length of the {url_alias}.alias field from the schema.

Return value

int An integer of the maximum URL alias length allowed by the database.

File

core/modules/path/path.inc, line 683
Miscellaneous functions for Path module.

Code

function _path_get_schema_alias_maxlength() {
  $maxlength = &backdrop_static(__FUNCTION__);
  if (!isset($maxlength)) {
    $schema = backdrop_get_schema('url_alias');
    $maxlength = $schema['fields']['alias']['length'];
  }
  return $maxlength;
}