pasting code into atto editor

Re: pasting code into atto editor

by Sam Mudle -
Number of replies: 0

I have a few programming courses in my moodle in which users are pasting code into the atto editor in the forum module.

what I mean by code is for example: SQL syntax, JavaScript syntax, PHP code syntax etc.
problem is: on one hand I need my users to be able to insert such code for others members of the course to see what they pasted.
on the other hand: these syntaxes are dangerous and cannot be inserted in database and presented as is to other users.

I was wondering how to overcome this? maybe there is some kind of "code" wrap button like I've seen on other forums that I can add to atto editor?

You don't need to worry about code injection issues in the ATTO editor.  It won't matter what type of code your students slap into the editor, it will not be run on the server.  It's sanitized really well.

Average of ratings: Useful (1)