Vanilla open source was terminated 1 January 2025 by Higher Logic. See this announcement for more information.

Can't display a custom Module

I created a test module class.helloworldmodule.php
<?php if (!defined('APPLICATION')) exit(); class HelloWorldModule extends Module { public function AssetTarget() { return 'Panel'; } public function ToString() { return 'Hello World!'; } }
added it to /vanilla/modules folder

then opened class.discussionscontroller.php in /vanilla/controllers folder
and added
$this->AddModule('HelloWorldModule');
or
$this->AddModule('HelloWorldModule' , 'Content');
to call the new module.

I believe I did everything right that's explained in the documentation to add a new module but still something is wrong I guess.
Tagged:

Answers

Sign In or Register to comment.