module null param in meta
This commit is contained in:
parent
60358ef4be
commit
f421952fc6
@ -2861,13 +2861,12 @@ class core extends common
|
||||
// Importe le module
|
||||
else {
|
||||
// Id du module, et valeurs en sortie de la page si il s'agit d'un module de page
|
||||
|
||||
if ($access and $this->getData(['page', $this->getUrl(0), 'moduleId'])) {
|
||||
$moduleId = $this->getData(['page', $this->getUrl(0), 'moduleId']);
|
||||
$this->addOutput([
|
||||
'title' => $title,
|
||||
// Meta description = 160 premiers caractères de l'article
|
||||
'metaDescription' => $this->getData(['page', $this->getUrl(0), 'moduleId']) === 'blog' && !empty($this->getUrl(1))
|
||||
'metaDescription' => $this->getData(['page', $this->getUrl(0), 'moduleId']) === 'blog' && !empty($this->getUrl(1)) && in_array($this->getUrl(1), $this->getData(['module']))
|
||||
? strip_tags(substr($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'content']), 0, 159))
|
||||
: $this->getData(['page', $this->getUrl(0), 'metaDescription']),
|
||||
'metaTitle' => $this->getData(['page', $this->getUrl(0), 'metaTitle']),
|
||||
|
Loading…
Reference in New Issue
Block a user