Last active
December 2, 2019 14:33
-
-
Save CrazyBoy49z/1249f7afdbf5f15204d3143c64f57554 to your computer and use it in GitHub Desktop.
Добавление модификатора ignore в Fenom MODX
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
У многих проблема с выводом тегов в фигурных скобках в Fenom MODX, Как обойты? | |
/** @var modX $modx */ | |
switch ($modx->event->name) { | |
case 'pdoToolsOnFenomInit': | |
$fenom->addModifier('ignore', function ($input) use ($modx) { | |
$input = "{ignore}{$input}{/ignore}"; | |
return $input; | |
}); | |
break; | |
} | |
Вешать на событие pdoToolsOnFenomInit | |
https://sitename.com?utm_content=gid%7C%7Bgbid%7D%7Caid%7C%7Bad_id%7D%7C%7Bphrase_id%7D_%7Bretargeting_id%7D | |
В шаблоне {$.get.utm_content | ignore} вывод gid|{gbid}|aid|{ad_id}|{phrase_id}_{retargeting_id} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment