Moodle Block Development

This is a quick response to David’s post today. We are endeavoring to collaborate on the development of a Moodle block. A more detailed explanation can be found on David’s blog.

On my local Moodle installation I found that the following line didn’t work for the editing teacher at all so I changed it accordingly. This page has some more options we could try.

if ( has_capability( 'moodle/legacy:teacher', $context )) {

changed to

if ( has_capability( 'moodle/legacy:editingteacher', $context )
|| has_capability( 'moodle/legacy:teacher', $context )) {

In response to David’s comment about PHP OO and a factory class. I think that is exactly what is required. Of course the learning curve is going to be rough.


One thought on “Moodle Block Development”

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s