How to change the Home module

27.1. How to change the Home module

Figure 27-1. Administration panel: Modules.

Administration panel: Modules.

In PHP-Nuke, the "Home" module is the module that is displayed in the central column of the index.php page. The default Home module is the News module, i.e., upon opening the index.php page, we get the usual news summary of the News module in the central column. However, you may want to change this behaviour and display, say, the Downloads module in the Home instead. You could of course use some kind of redirection (see Section 18.6.1 and Section 18.6.3 for ideas) to redirect your visitors to the Downloads module, however this is not necessary: PHP-Nuke allows you to change the module that will be "put in Home" from the modules administration panel (Section 7.1).

Normally, to change the Home module, you proceed as follows: go to the administration panel, click on "Modules". You get a table of modules (Figure 27-2).

Figure 27-2. Modules administration panel.

Modules administration panel.

Find the line that contains the information on the "Downloads" module. There, there is a link "Put in Home", besides the "Edit" and "Delete" links. Click on "Put in Home" and answer with "Yes" the question that follows (you may have to scroll to see it):

Default Homepage Module
Are you sure you want to change your Homepage from Web_Links To Downloads?
[ No | Yes ]

Then the Downloads module will be your "Home".

However, this may not work with some themes like Sand_Journey (which is one of the standard ones).

The reason is the following code in index.php (see Setting a module to be shown on Home page):

if (file_exists("themes/$ThemeSel/module.php")) {

For the Sand_Journey theme (i.e. when $ThemeSel is "Sand_Journey"), this means that themes/Sand_Journey/module.php file is included in index.php, if it exists. But if it is included, it changes the default module, because the module.php file for the Sand_Journey theme contains:

$default_module = "News";

overriding any other settings. Thus, to be able to change the Home module with such a theme, you have to rename, delete, or remove the module.php file from the theme folder. No file, no cry.


Site Info

Last SeenLast Seen
  • neralex
  • hicuxunicorni...
Server TrafficServer Traffic
  • Total: 403,544,791
  • Today: 18,894
Server InfoServer Info
  • May 29, 2020
  • 09:04 am CEST