multilang filter on front page site news

multilang filter on front page site news

by Michael Zehr -
Number of replies: 0

I'm having a problem using the multi-lang filter in the site news on the front page (moodle 2.4.3).

I created a post with site news, used the span class="multilang" lang="xx" syntax.

The problem is that the site news is abbreviated on the front page with a link to "read the rest of this topic."

But the truncation appears to be done before the multi-lang filter is applied, so the last paragraph for one language is displayed in the language of the first language, regardless of which language is selected.

Let me explain that in more detail.  My site news post has two paragraphs and I'm displaying in three languages.  If I put the languages in the order of english, spanish, french of each paragraph, then it looks right in english and spanish.  If I switch to french then the last paragraph appears in english.  If I change the order of languages in the post, the language affected changes.  My conclusion is that the post is truncated before the second paragraph's text in french, so when the filter is applied it doesn't see the translation, and defaults to the first language.  If I click on "read the rest..." then all of it appears in the correct language.

I could fall back to using just an html block instead of site news on the front page, as the information won't be changing very rapidly, but I was hoping to use the site news to make it a bit easier to manage.

Average of ratings: -