通过模块名称的方式加载模块
    /**
     * @description  : method to render the module in component or moduel by moduel name
     * @param         {*} $modName
     * @param         {*} $modTitle
     * @return        {*}
     */
    static public function renderModuelByName($modName, $modTitle)
    {
        jimport('joomla.application.module.helper');
        $module = JModuleHelper::getModule($modName, $modTitle);
        echo JModuleHelper::renderModule($module);
    }
调用方法:
<?php TplChahuawuHelper::renderModulesByName('m_header_menu') ?>
通过模块位置的方法加载模块
    /**
     * @description  : method to render the module in component or moduel by moduel position
     * @param         {*} $position
     * @return        {*}
     */
    static public function renderModulesByPosition($position)
    {
        jimport('joomla.application.module.helper');
        $modules = JModuleHelper::getModules($position);
        foreach ($modules as $module) {
            echo JModuleHelper::renderModule($module);
        }
    }
调用方法:
<?php TplChahuawuHelper::renderModulesByPosition('position') ?>