By default PHP-Fusion will let you modify the footer from the admin panel. This however displays at the very bottom of your PHP-Fusion site, and if you’d like to instead place a footer in-between your front page content and the bottom of the page, this article will explain that in detail.
Modify the sub-footer include file
Unlike the main footer that is editable from the admin panel, the sub-footer must be manually modified via a footer_includes.php file. Using the steps below I’ll walk you through this process.
- First if you don’t already know how to, familiarize yourself with how to edit a file on my server.
- The file you need to edit is going to be relative to your PHP-Fusion installation path, located at /includes/footer_includes.php.
For me the full path to this file was /home/userna5/public_html/phpfusion/includes/footer_includes.php
This is what the file should look like by default, basically a bunch of comments but no actual code:
<?php
/*——————————————————-+
| PHP-Fusion Content Management System
| Copyright (C) 2002 – 2011 Nick Jones
| https://www.php-fusion.co.uk/
+——————————————————–+
| Filename: footer_includes.php
+——————————————————–+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+——————————————————–*/
//Add your custom include files for the footer here
?>
- Below the line //Add your custom include files for the footer here, is where we will be inserting our own sub-footer data. So you should end up with something like this:
//Add your custom include files for the footer here
echo “<center>This is my sub-footer for PHP-Fusion!</center>”;
After you save the file you should be able to refresh your PHP-Fusion website and see your new sub-footer. In the example image below, you can see that I’ve highlighted where each type of footer is getting loaded from.
Sub-footer |
/includes/footer_includes.php |
Site footer |
Admin panel > Site footer |
Copyright footer |
/includes/theme_functions_include.php |
You should now understand how to modify the sub-footer of your PHP-Fusion website, and also where the multiple places that footer text is getting set at.