Hey,
I'm hoping someone could help me. I am trying to put my own block into my moodle page. I am following the online instructions on this page:
http://docs.moodle.org/en/Blocks_Howto
I have done the first bit - so its just a simple html block. The code is here:
<?php
class simple_html extends block_base {
function init() {
$this->title = get_string('simplehtml', 'simple_html');
$this->version = 2004123000;
}
function get_content() {
if ($this->content !== NULL) {
return $this->content;
}
$this->content = new stdClass;
$this->content->text = 'A block';
$this->content->footer = 'A foot';
return $this->content;
}
}
?>
However when I put the folder into the 'blocks' folder - no blocks can be added on my moodle page. I really have no idea what I am doing wrong as I am following the instructions on the page!!
Can someone please help?
Thank you!
Blocks
New Block
This discussion has been locked so you can no longer reply to it.