开发者

how Joomla back-end's core works?

In the Joomla back-end, the administrator would do modifications using the GUI.

Say a module is enabled(just click the check box).

What happens in php-level?(what happens to the code?)

Some trivial assumptions I come up with are,

-commenting/uncommenting

-some code snippets are 开发者_StackOverflow社区added/removed

-configuration(ex: xml) files are modified/created


Joomla itself doesn't really modify files on disk much at all. The only exceptions I can think of are:

  • Installing an extension (writes to '/tmp', and then the final location for the extension files)
  • Saving global configuration options (writes to '/configuration.php')
  • Caching (writes to '/cache')

All other configuration changes, entered data, etc from the admin area (and frontend) are stored in the Joomla database.

So the example given (enabling/disabling a module) doesn't edit or create any files. It only makes changes in a core database table (jos_modules, if your DB prefix is 'jos_'). Module inclusion on all pages is dynamically evaluated per page-load based on the code in your template, as @Hanny mentions.


If you read the index.php file in of the template you're using - you'll find that all the positions of the template are included in that file <jdoc include="position10" /> or something of that nature is what it will say.

Usually the templates use CSS to help determine how to 'shape' the page depending on which modules are enabled, along with 'if,then,else' statements on the php level. Read through the index.php file and you'll probably see that.

if "module10" then use "rightmodule.css" type thing - which then may hold changes to be made to certain containing div's with regards to width and that sort of thing.

No commenting/uncommenting happens, no code snippets are added and no configuration files are modified/created (at least as far as I know, and I've worked to design a component for Joomla previously). It's all if statements and tying that together with the module positions that are laid out in the templates index.php file.

This is a simplified answer, but I think it answers what you've asked.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜