1

This is the first time I'm working with Joomla and I try to get started with simple hello world module.

I have created hello world module as described on http://docs.joomla.org/J3.1:Creating_a_simple_module/Developing_a_Basic_Module.

Configured it like this:

enter image description here enter image description here

But hello world text is not rendered:

enter image description here

I also tried to dump from mod_helloworld.php, but look like it is not interpreted at all. I'm using Joomla! 3.1.5

Any idea what am I doing wrong?

umpirsky
  • 9,902
  • 13
  • 71
  • 96
  • 1
    try assigning it to `position-7` which is on the right hand side where your main menu and login modules are and see if it renders. If not, then please provide the code from `mod_helloworld.php` and `default.php` – Lodder Nov 21 '13 at 15:07
  • Does `position-12` belongs to your template ? – kmas Nov 21 '13 at 15:09
  • Ha, `position-7` worked, thanks! I am such a noob with this positions, will read more about it. – umpirsky Nov 21 '13 at 15:18
  • yeah it's kind of weird that Joomla provide positions that haven't been defined in the index.php of the template folder. You should write an answer and mark it as correct to people know the issue has been solved – Lodder Nov 21 '13 at 15:23
  • @Lodder Feel free to write one and I will accept so you get credits, since you solved my problem. Thanks. – umpirsky Nov 21 '13 at 16:24
  • Joomla "provides" the positions of all the published templates you have installed. It's not really weird at all, not providing all of them would be really weird. – Elin Nov 22 '13 at 02:28

1 Answers1

1

The default Joomla template (Protostar) comes with predefined positions such as position-1, position-2, position-1 etc, however not every single one is defined in the index.php of the template folder and therefore if you assign a module to one of these undefined positions, it won't be displayed.

Assign your module to position-7 which is a pre-defined position on the right hand side of your template. Other modules such the main menu and login also use this position.

Lodder
  • 19,758
  • 10
  • 59
  • 100