Lai32290
Lai32290

Reputation: 8548

Why moodle block is not showing?

I have fallowing Moodle document for creating a new block, called "simplehtml" liked document, I can install this block, but why when I put this fallowing code in layout, it is not returning anything for rend?

Code in layout for call my block:

<?php echo $OUTPUT->blocks('simplehtml', 'span4 desktop-first-column'); ?>

Upvotes: 0

Views: 1183

Answers (1)

Jakub Kania
Jakub Kania

Reputation: 16467

That's not how blocks work. Block is like a widget. Add it to the page using the interface:

https://docs.moodle.org/29/en/Block_settings#Adding_a_block_to_a_page

Upvotes: 1

Related Questions