Totara Learn Open Discussions

Adding JavaScript to HTML Blocks

 
Nicole Ball
Adding JavaScript to HTML Blocks
بواسطة Thursday, 12 September 2024, 2:53 PM - Nicole Ball
 

I need to add some JavaScript to an HTML block for a Totara dashboard. Is this possible?

Thanks!

Craig Eves
Re: Adding JavaScript to HTML Blocks
بواسطة Thursday, 12 September 2024, 7:27 PM - Craig Eves (Totara Support)
مجموعة Totara

Hi Nicolas

The embedding of advanced HTML is a security risk and will by default be filtered out using HTML purifier .

Although we don't recommend this there are some settings that would allow some advanced HTML content see https://totara.atlassian.net/wiki/spaces/DEV/pages/121185890/Totara+13+changes+to+content+sanitisation for details

regards