0

我面临着对大型 Joomla 网站进行逆向工程的任务——进行更改和添加。

我可以很容易地找到页面后面的模板。然而,要找到哪个视图文件将变量值提供给该模板是很困难的。

任何提示或建议将不胜感激。

谢谢阅读。

4

1 回答 1

0

我认为您对 Joomla! 模板在 1.5 中工作。

模板不会通过它们显示的视图传递值。

模板就是这样,一个由 Joomla 处理的模板,它查找<jdoc>标签并有效地将它们替换为由页面生成的输出component和任何modules显示在页面上的输出。(插件也可以处理页面内容,但这是一个较低的级别)。

例如,您会在Joomla! 附带jdoc的模板中找到这些语句!rhuk_milkyway1.5.x

<jdoc:include type="modules" name="top" />
<jdoc:include type="modules" name="user3" />
<jdoc:include type="modules" name="user4" />
<jdoc:include type="modules" name="breadcrumb" />
<jdoc:include type="message" />
<jdoc:include type="modules" name="left" style="rounded" />
<jdoc:include type="modules" name="user1" style="xhtml" />
<jdoc:include type="modules" name="user2" style="xhtml" />
<jdoc:include type="component" />
<jdoc:include type="modules" name="footer" style="xhtml"/>
<jdoc:include type="modules" name="right" style="xhtml"/>
<jdoc:include type="modules" name="syndicate" />
<jdoc:include type="modules" name="debug" />

要找出是什么在页面的特定位置生成内容,您需要确定它是模块还是主要组件。如果它是生成内容的组件(这通常是生成 Joomla! 页面的主体),那么您可以在其菜单项中找到该组件的设置。

如果它是生成您感兴趣的页面部分的模块,您需要打开Menu Manager然后找到相关模块并打开它以获取它的设置。

于 2013-04-12T00:43:18.297 回答