multilang html-block titleI

multilang html-block titleI

بذریعہ Daniel Schimrik -
جوابات کی تعداد: 7

Hello,

I am working currently on a multilanguage moodlesite with 4 languages. The content and title of content is translated as expected.

If inserting an HTML-block, I can insert multilang content, but no multilang title of this block. The language settings in the title are ignored by Moodle and it shows all titles at once.

Is there any way to also translate the title of HTML-blocks? (I am running Moodle 1.9)


Regards, Daniel

درجہ بندی کا اوسط: -
Daniel Schimrik کے جواب میں

Re: multilang html-block titleI

بذریعہ Gordon Bateson -
Core developers کی تصویر Peer reviewers کی تصویر Plugin developers کی تصویر
I have not tested this, but in the absence of other suggestions, how about the following:
  1. open "blocks/moodleblock.class.php" with a text editor
  2. locate the following line (around line 356 in the "_title_html" function):
    $title .= '<h2>'.$this->title.'</h2>';
  3. change the above line to:
    $title .= '<h2>'.filter_text($this->title).'</h2>';
  4. saved the modified file
hope that helps
Gordon
Gordon Bateson کے جواب میں

Re: multilang html-block titleI

بذریعہ Daniel Schimrik -
Hello Gordon,

I tried your solution and it works perfectly! So I posted a message to the bug-tracker about this issue.

@Anthony: I had already activated filter anything in the filter section of Moodle

Regards, Daniel
Daniel Schimrik کے جواب میں

Re: multilang html-block titleI

بذریعہ Nicolas Martignoni -
Core developers کی تصویر Documentation writers کی تصویر Particularly helpful Moodlers کی تصویر Plugin developers کی تصویر Testers کی تصویر Translators کی تصویر
Could you point us to the issue number?
Daniel Schimrik کے جواب میں

Re: multilang html-block titleI

بذریعہ Anthony Borrow -
Core developers کی تصویر Plugin developers کی تصویر Testers کی تصویر
Daniel - Before modifying the code, try going to the Administration Block and under filter settings there should be an option to filter all strings. Turn that on and see if it does the trick. Peace - Anthony