Перейти к содержимому Перейти к боковой панели

Эта тема содержит 0 ответ, имеет 0 voices.

Последнее обновление: hayesP 8 месяцев, 2 недели назад.

При содействии: Noman.

Автор Сообщения
14 апреля, 2025 в 1:31 пп #16929781

hayesP

Background of the issue:
We have a custom tool on an existing English language site that uses get_terms() to get all terms from a taxonomy. The taxonomy is set to translatable, and the taxonomy terms have been translated.

Symptoms:
get_terms() returns all the English terms when the language is set to English, but returns nothing when the language is set to Spanish.

Questions:
Why does get_terms() return nothing for Spanish when the taxonomy terms have been translated?
How can we get get_terms() to return the appropriate taxonomy terms for the current language?