Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ignore не работает во вложенном цикле foreach #344

Open
AntonFix opened this issue Jan 30, 2024 · 0 comments
Open

Comments

@AntonFix
Copy link

AntonFix commented Jan 30, 2024

Всем привет.
Использую MODX Revolution 3.0.4, pdotools-3.0.2-pl, migx-3.0.2-beta1.

`
{set $faqRubric = $_modx->resource.faqRubrics | fromJSON}

{foreach $faqRubrics as $faqRubricItem}

<h2>{$faqRubricItem.titleRubric}</h2>

{set $faqRows = $faqRubricItem.faq | fromJSON}

{foreach:ignore $faqRows as $idx => $row}
	<h3>{$row.q}</h3>
	<p>{$row.a}</p>
{/foreach}

{/foreach}
`

Не отображает ничего, кроме html-разметки.

Из-за того, что в {$row.a} находится скопипастенный текст, в котором встречается мусор в разметке типа такого

GFd1VV1

Как заставить работать ignore во вложенном цикле?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant