Files
friendica/src/Module
Michael Vogel f0a0c6b822 Merge pull request #8982 from MrPetovan/task/8918-move-mod-common
Move mod/common.php to src/ Part 3: Add Module\Contact\Contacts class
2020-08-07 20:51:02 +02:00
..
2020-08-06 18:53:45 +00:00
2020-07-23 06:11:21 +00:00
2020-02-22 08:54:28 +00:00
2020-07-23 06:25:01 +00:00
2020-08-06 22:59:09 -04:00
2020-08-04 05:46:00 +00:00
2020-07-23 06:25:01 +00:00
2020-07-23 06:25:01 +00:00
2020-07-29 05:12:16 +00:00
2020-08-05 03:36:37 +00:00
2020-04-28 11:52:51 +00:00
2020-02-09 15:45:36 +01:00
2020-02-09 15:45:36 +01:00
2020-07-23 06:25:01 +00:00
2020-07-13 13:26:09 +00:00
2020-07-13 14:16:44 +00:00
2020-07-13 14:16:44 +00:00
2019-05-01 20:17:15 +02:00
2020-03-29 11:36:04 +02:00
2020-07-08 09:14:34 -04:00

Friendica\Module

The Module namespace contains the different modules of Friendica. Each module is loaded through the App.

There are mainly two types of modules:

  • frontend modules to interact with users
  • backend modules to interact with machine requests

Frontend modules

This type of modules mainly needs a template, which are generally located at view/templates/.

A frontend module should extend the BaseModule, especially the content() method.

Backend modules

This type of modules mainly responds either with encoded XML or with JSON output. It isn't intended to respond with human readable text.

A frontend module should extend the BaseModule, especially the rawContent() method.

Routing

Every module needs to be accessed within a route. The routes are defined inside Router->collectRoutes().

Use the given routes as a pattern for further routes.

The routing library and further documentation can be found here.