Most webmasters would probably like to adapt the mm_forum to the looks of their website. In this section, I will introduce several ways to customize the mm_forum extension exactly to your needs.
To change the look and feel of the mm_forum extension you are allowed to edit all HTML template files in the backend module. In order to do this go to Tools ► mm_forum and select option “Templates” and than select the template file you want to edit.
The mm_forum extension works with different design sets. These design sets contain the templates needed for generating the mm_forum output. Each design is meant to contain the same template files describing different designs for outputting the same things. You can edit the mm_forum templates directly in the backend module. However, you will not be able to edit template files that are in the default design set. To edit template files, you have to create a new design set. The backend module will do this by just copying the default design set into a new directory. The reason for this is that the default design set is overwritten each time the administrator updates the extension, so editing files directly in the default design set would be extremely risky. Custom design sets are stored in a directory outside the mm_forum extension directory. By default, this alternative template directory is fileadmin/ext/mm_forum/tmpl/. This value can be changed using the mm_forum configuration tool. You can specify one design set as active. The template files from the active design set will be used for rendering the content of the mm_forum in the frontend.
The mm_forum stylesheet file is also affected by the design set mechanism, which allows you to totally vary the mm_forum output just be defining different design sets.
Of course you can also edit the template files directly in the EXT:mm_forum/res/tmpl/ directory or define other template files in TypoScript. To see which TypoScript values you have to change for that, see the fully documented file EXT:mm_forum/ext_typoscript_setup.txt.
NOTE: It is not recommended to edit any files directly in the extension directory, since your changes might be overwritten during future updates. Instead, you should either change the file paths in TypoScript to your custom files or work with design sets.
A design set contains also CSS files and images. This means, when you create a new design set, all mm_forum images will be duplicated into this new design set too, allowing you to edit and store these update-save.
As of mm_forum version 0.1.5 all buttons used in the mm_forum are generated using TypoScript templates. These can be found in the „buttons“ object of the regarding plugin. The parameters of the button are stored in the data array of the content object (accessible for example by stdWrap.field). There are the following fields:
Field name: | Description: | |
button_iconname | The name of the icon used for this button | |
button_label | The text label used for this button | |
button_link | The link of the button | |
button_atagparams | Additional parameters for the buttons <A>-Tag |
By default, the mm_forum contains two button templates, one for text based buttons and one for image buttons. These are stored in plugin.tx_mmforum_pi1.buttons_text and plugin.tx_mmforum_pi1.buttons_plugin. This allows you to switch between text and image buttons by just copying the regarding object into the buttons object:
plugin.tx_mmforum_pi1.buttons < plugin.tx_mmforum_pi1.buttons_text
In version 0.1.6, text buttons are enabled by default.
As of version 0.1.6, you can switch between classic and modern topic icons. The classic icons are identical with those used in the previous versions of the mm_forum extension. The modern icons by default consist of an „icon map“ and are configured by a TypoScript template located in plugin.tx_mmforum_pi1.topicIcon. The necessary topic parameters are stored in the data array of the content object (accessible for example by stdWrap.field). There are the following fields:
Field name: | Description: | |
unread | Equals 1 if the topic is unread, otherwise 0 | |
unanswered | Equals 1 if the topic is unanswered, otherwise 0 | |
closed | Equals 1 if the topic is closed, otherwise 0 | |
solved | Equals 1 if the topic is solved, otherwise 0 | |
hot | Equals 1 if the topic is hot, otherwise 0 |