Documentation

Core_Meta
in package

Apply Meta-tags templates, e.g. {uppercaseFirst group.name}, {this.seoFilter ": " ", "}, {date(d.m.Y)}

Tags
subpackage

Core

version
7.x
author

Hostmake LLC

copyright

© 2005-2022 ООО "Хостмэйк" (Hostmake LLC), http://www.hostcms.ru

Table of Contents

$_functions  : array<string|int, mixed>
Array of functions [name] => callable
$_objects  : array<string|int, mixed>
Array of objects [name] => $object
$_replaceFunctions  : array<string|int, mixed>
Predefined functions
addFunction()  : self
Add function
addObject()  : self
Add object
apply()  : string
Apply template, e.g. {group.name}, {toLower group.name}, {toLower group.groupPathWithSeparator " / " 1}
clear()  : self
Clear meta
_callback()  : string
Replace callback function
_parseArgs()  : array<string|int, mixed>
Parse args

Properties

$_functions

Array of functions [name] => callable

protected array<string|int, mixed> $_functions = array()

$_objects

Array of objects [name] => $object

protected array<string|int, mixed> $_objects = array()

$_replaceFunctions

Predefined functions

protected array<string|int, mixed> $_replaceFunctions = array('toUpper' => 'mb_strtoupper', 'toLower' => 'mb_strtolower', 'uppercaseFirst' => 'Core_Str::ucfirst', 'lowercaseFirst' => 'Core_Str::lcfirst')

Methods

addFunction()

Add function

public addFunction(string $name, callable $callable) : self
Parameters
$name : string
$callable : callable
Return values
self

addObject()

Add object

public addObject(string $name, string $object) : self
Parameters
$name : string
$object : string
Return values
self

apply()

Apply template, e.g. {group.name}, {toLower group.name}, {toLower group.groupPathWithSeparator " / " 1}

public apply(string $str) : string
Parameters
$str : string
Return values
string

clear()

Clear meta

public clear() : self
Return values
self

_callback()

Replace callback function

protected _callback(array<string|int, mixed> $matches) : string
Parameters
$matches : array<string|int, mixed>
Return values
string

_parseArgs()

Parse args

protected _parseArgs(string $str) : array<string|int, mixed>
Parameters
$str : string
Return values
array<string|int, mixed>

Search results