XoopsCore25 icon indicating copy to clipboard operation
XoopsCore25 copied to clipboard

Add two (2) methods for Admin footer to ModulesAdmin

Open zyspec opened this issue 5 years ago • 1 comments

ENHANCEMENT Propose adding new methods to the ModuleAdmin class in .\Frameworks\moduleclasses\moduleadmin\moduleadmin.php

Adding two (2) new methods for the admin footer rendering/display to both standardize the admin footer and reduce "future" update to the footer in modules. Propose adding renderFooterInfo() and displayFooterInfo() methods. By adding this to the ModuleAdmin class most modules can change their footer to just call \Xmf\Module\Admin::getInstance()->displayFooterInfo();. The renderAbout() method can easily be modified to use this code too.

Attached is a copy of moduleadmin.php with the changes.

Note: One additional change that can/should be made if this is implemented is the _AM_MODULEADMIN_ADMIN_FOOTER define (in ./language/english/main.php) should be modified to remove the <div> HTML styling - which is also a good thing. The updated define would look like this:

define('_AM_MODULEADMIN_ADMIN_FOOTER', "This module is maintained by the <a class='tooltip' rel='external' href='http://xoops.org/' title='Visit XOOPS Community'>XOOPS Community</a>");

moduleadmin.zip

zyspec avatar Mar 13 '19 17:03 zyspec

If this (or similar) implementation is used then to further improve this the HTML should be removed from the _AM_MODULEADMIN_ADMIN_FOOTER definition.

zyspec avatar Dec 12 '21 16:12 zyspec