Joomla,将位置添加到文件中


Joomla, add position into file

我想将我的Joomla模块与位置连接起来。

如何创建此职位(用户职位)?此文件在模板中的何处?

如果必须创建新职位(当前模板中未定义),则必须编辑/templates/template_name/index.php并在需要的地方添加jdoc:include语句:

<jdoc:include type="modules" name="new-position" style="xhtml" />

然后编辑/templates/template_name/templateDetails.xml添加位置:

<positions>
    ...
    <position>new-position</position>
    ...
</positions>

在某些模板中,位置不能在index.php中,在这种情况下,搜索定义模板布局的其他文件(总是在/template/template_name/文件夹或子目录中)。

也可以考虑在Joomla.stackeexchange.com上询问Joomla相关问题,以获得更好的答案!

通常,每个模板都包括一些职位,请首先检查模板中可用的职位

转到系统全局配置模板
在此启用选项预览模块位置

现在,如果您转到扩展模板可以单击小眼图标或在您的url中添加类似的内容:

  • 你的网站.com/?tp=1

现在,您可以转到扩展模块您的模块,在此处选择您选择的位置