Prepopulate a moodle form editor with content

Re: Prepopulate a moodle form editor with content

by Neill Magill -
Number of replies: 0
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Moodle forms have a set_data() method that allows you to populate the form.

You pass an array or object containing data you wish to populate your form with, the key/property names need to match the field names of the form.