Totara Learn Open Discussions

Display dynamic variable to user?

 
MaurinJoyce
Display dynamic variable to user?
MaurinJoyce 发表于 2020年06月16日 Tuesday 00:47
小组 Partners

Hello!

Do we have a way to customize a message and display it to the user with fields from its profile?

Like "Welcome <firstname>!"

I tried with the followings I've met on the language pack, normaly sent by email:

  • [[firstname]]
  • [firstname]
  • {$a->firstname}

None is displaying the firstname. How can we get and display this value from the platform?

My final goal is to add a new field ( https://help.totaralearning.com/display/TL12/User+Profile+Fields ) and to show this value to the user through the platform.

Best regards,

Craig Eves
Re: Display dynamic variable to user?
Eves (Totara Support)Craig 发表于 2020年06月16日 Tuesday 19:45
小组 Totara

Hi Joyce

Which message type were you wanting to customise - some messages use the language pack string to include content so can have the language string changed 

Some messages come from settings within Totara that can be changed such as seminar messaging and program messaging.

Some messages come from the totara code itself so the code would need changing.

regards



CarrickAlex
Re: Display dynamic variable to user?
CarrickAlex 发表于 2020年07月21日 Tuesday 12:58
小组 Partners

Hey Joyce - I would check out the Filter Codes moodle plugin. I think it should do exactly what you're looking for.

MaurinJoyce
Re: Display dynamic variable to user?
MaurinJoyce 发表于 2020年07月23日 Thursday 06:00
小组 Partners

Hi Alex,

Sorry I took so long to answer!

Thanks for your answer, we'll dig into this plugin to see if it works the way we would like :)

Bests,