InMotion Hosting Support Center

In this article I'm going to teach you how to add a new custom module to your PHP-Nuke website.

In PHP-Nuke, modules are used in order to build up the menu items of your site. You could create for example a module that has some simple text content and a link to a remote website. Visitors to your site would be able to get to this page by clicking on the module's link in your Modules menu.

Creating a new module in PHP-Nuke

Following the steps below I'll walk you through creating a new custom module called Support, that simply has some text and then a link back to our support center.

  1. Login to your cPanel
  2. Under the Files section, click on File Manager, select Web Root and click on Go.
  3. Navigate to the directory you've installed PHP-Nuke to, then go into the modules directory.
  4. In the top menu, click on + New Folder, then name the folder what you'd like to name your module. In this case I've named mine Support, then click on Create New Folder.
  5. Now click on the newly created Support modules folder.
  6. Next click on + New File, name your new file index.php, then click on Create New File.
  7. Now right-click on the newly created index.php script, and select Edit.
  8. This is the example code I have used for my module:

    if (!eregi("modules.php", $PHP_SELF)) {
    die ("You can't access this file directly...");
    $index = 1;
    $module_name = basename(dirname(__FILE__));

    echo "<p>This is a test module!</p>";

    echo '<a href="">InMotion Support Center</a>';


  9. Now click on Save Changes up at the top-right.

Activating newly created module in PHP-Nuke

Now that you've created a new module, we need to login to PHP-Nuke to set it to active. Follow along with these steps to accomplish that.

  1. Login to your PHP-Nuke admin dashboard.
  2. In the 2nd row, 4 icons over, click on Modules.
  3. Scroll down till you see the newly created Support module, and click on the cog icon to the far-right of it to enable the module.
  4. Now if you navigate back to your PHP-Nuke main page, you should see under the Modules menu the new Support one, and clicking on it will take you to the page that includes our text and link!

You should now understand the very basics of creating a new custom module to use with PHP-Nuke.

Was this article helpful?
Continued Education in Course 103: PHP-Nuke Modules and blocks
You are viewing Section 3: Add new custom module in PHP-Nuke
Section 2: How to manage modules from the sidebar
Section 4: Removing Modules from the Menu PHP-Nuke

Related Questions

Here are a few questions related to this article that our customers have asked:
Ooops! It looks like there are no questions about this page.
Would you like to ask a question about this page? If so, click the button below!
Ask a Question

Support Center Login

Our Login page has moved, Click the button below to be taken to the login page.

Post a Comment

Email Address:
Phone Number:

Please note: Your name and comment will be displayed, but we will not show your email address.

0 Questions & Comments

Post a comment

Back to first comment | top

Need more Help?


Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail:
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!