From 65998987743e56249d0327cf719f76c66de09fcd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Mon, 23 Apr 2018 11:45:44 +0200 Subject: [PATCH 01/10] [DOCS] Account docs: Fix titles --- doc/Account-Basics.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/Account-Basics.md b/doc/Account-Basics.md index 7883a346f..da865ad2b 100644 --- a/doc/Account-Basics.md +++ b/doc/Account-Basics.md @@ -16,19 +16,19 @@ If you'd like to have your own server, you can do that too. Visit [the Friendica website](http://friendi.ca/) to download the code with setup instructions. It's a very simple installation process that anybody experienced in hosting websites, or with basic Linux experience can handle easily. -###OpenID +### OpenID The first field on the Registration page is for an OpenID address. If you do not have an OpenID address or do not wish to use OpenID, leave this field blank. If you have an OpenID account elsewhere and wish to use it, enter the address into this field and click 'Register'. Friendica will attempt to extract as much information as possible from your OpenID provider and return to this page with those items already filled in. -###Your Full Name +### Your Full Name Please provide your full name **as you would like it to be displayed on this system**. Most people use their real name for this, but you're under no obligation to do so yourself. -###Email Address +### Email Address Please provide a valid email address. Your email address is **never** published. @@ -38,7 +38,7 @@ This doesn't have to be your primary email address, but it does need to be a rea You can't get your initial password, or reset a lost password later without it. This is the only bit of personal information that has to be accurate. -###Nickname +### Nickname A nickname is used to generate web addresses for many of your personal pages, and is also treated like an email address when establishing communications with others. Due to the way that the nickname is used, it has some limitations. @@ -47,7 +47,7 @@ It also must be unique on this system. This is used in many places to identify your account, and once set it cannot be changed. -###Directory Publishing +### Directory Publishing The registration form also allows you to choose whether or not to list your account in the online directory of your node. This is like a "phone book" and you may choose to be unlisted. @@ -55,7 +55,7 @@ We recommend that you select 'Yes' so that other people (friends, family, etc.) If you choose 'No', you will essentially be invisible and have few opportunities for interaction. Whichever you choose, this can be changed any time from your Settings page after you login. -###Register +### Register Once you have provided the necessary details, click the 'Register' button. An email will be sent to you providing your account login details. From efdb7a3835bbaad168bf3c4fb1bf46a6d4fe705e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Mon, 23 Apr 2018 17:20:16 +0200 Subject: [PATCH 02/10] [DOCS] Addons: Restructure hooks --- doc/Addons.md | 375 +++++++++++++++++++++++++++++++++----------------- 1 file changed, 245 insertions(+), 130 deletions(-) diff --git a/doc/Addons.md b/doc/Addons.md index 4df91864b..221c68a81 100644 --- a/doc/Addons.md +++ b/doc/Addons.md @@ -321,184 +321,299 @@ Complete list of hook callbacks Here is a complete list of all hook callbacks with file locations (as of 01-Apr-2018). Please see the source for details of any hooks not documented above. -index.php: Addon::callHooks('init_1'); -index.php: Addon::callHooks('app_menu', $arr); -index.php: Addon::callHooks('page_content_top', $a->page['content']); -index.php: Addon::callHooks($a->module.'_mod_init', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_init', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_post', $_POST); -index.php: Addon::callHooks($a->module.'_mod_afterpost', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_content', $arr); -index.php: Addon::callHooks($a->module.'_mod_aftercontent', $arr); -index.php: Addon::callHooks('page_end', $a->page['content']); +### index.php -include/api.php: Addon::callHooks('logged_in', $a->user); -include/api.php: Addon::callHooks('authenticate', $addon_auth); -include/api.php: Addon::callHooks('logged_in', $a->user); + Addon::callHooks('init_1'); + Addon::callHooks('app_menu', $arr); + Addon::callHooks('page_content_top', $a->page['content']); + Addon::callHooks($a->module.'_mod_init', $placeholder); + Addon::callHooks($a->module.'_mod_init', $placeholder); + Addon::callHooks($a->module.'_mod_post', $_POST); + Addon::callHooks($a->module.'_mod_afterpost', $placeholder); + Addon::callHooks($a->module.'_mod_content', $arr); + Addon::callHooks($a->module.'_mod_aftercontent', $arr); + Addon::callHooks('page_end', $a->page['content']); + +### include/api.php + Addon::callHooks('logged_in', $a->user); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('logged_in', $a->user); -include/enotify.php: Addon::callHooks('enotify', $h); -include/enotify.php: Addon::callHooks('enotify_store', $datarray); -include/enotify.php: Addon::callHooks('enotify_mail', $datarray); -include/enotify.php: Addon::callHooks('check_item_notification', $notification_data); +### include/enotify.php + + Addon::callHooks('enotify', $h); + Addon::callHooks('enotify_store', $datarray); + Addon::callHooks('enotify_mail', $datarray); + Addon::callHooks('check_item_notification', $notification_data); + +### include/conversation.php -include/conversation.php: Addon::callHooks('conversation_start', $cb); -include/conversation.php: Addon::callHooks('render_location', $locate); -include/conversation.php: Addon::callHooks('display_item', $arr); -include/conversation.php: Addon::callHooks('display_item', $arr); -include/conversation.php: Addon::callHooks('item_photo_menu', $args); -include/conversation.php: Addon::callHooks('jot_tool', $jotplugins); + Addon::callHooks('conversation_start', $cb); + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); + Addon::callHooks('display_item', $arr); + Addon::callHooks('item_photo_menu', $args); + Addon::callHooks('jot_tool', $jotplugins); -include/security.php: Addon::callHooks('logged_in', $a->user); +### include/security.php + + Addon::callHooks('logged_in', $a->user); -include/text.php: Addon::callHooks('contact_block_end', $arr); -include/text.php: Addon::callHooks('poke_verbs', $arr); -include/text.php: Addon::callHooks('prepare_body_init', $item); -include/text.php: Addon::callHooks('prepare_body_content_filter', $hook_data); -include/text.php: Addon::callHooks('prepare_body', $hook_data); -include/text.php: Addon::callHooks('prepare_body_final', $hook_data); +### include/text.php -include/items.php: Addon::callHooks('page_info_data', $data); + Addon::callHooks('contact_block_end', $arr); + Addon::callHooks('poke_verbs', $arr); + Addon::callHooks('prepare_body_init', $item); + Addon::callHooks('prepare_body_content_filter', $hook_data); + Addon::callHooks('prepare_body', $hook_data); + Addon::callHooks('prepare_body_final', $hook_data); -mod/directory.php: Addon::callHooks('directory_item', $arr); +### include/items.php + + Addon::callHooks('page_info_data', $data); -mod/xrd.php: Addon::callHooks('personal_xrd', $arr); +### mod/directory.php + + Addon::callHooks('directory_item', $arr); -mod/ping.php: Addon::callHooks('network_ping', $arr); +### mod/xrd.php + + Addon::callHooks('personal_xrd', $arr); -mod/parse_url.php: Addon::callHooks("parse_link", $arr); +### mod/ping.php + + Addon::callHooks('network_ping', $arr); -mod/manage.php: Addon::callHooks('home_init', $ret); +### mod/parse_url.php + + Addon::callHooks("parse_link", $arr); -mod/acl.php: Addon::callHooks('acl_lookup_end', $results); +### mod/manage.php + + Addon::callHooks('home_init', $ret); -mod/network.php: Addon::callHooks('network_content_init', $arr); -mod/network.php: Addon::callHooks('network_tabs', $arr); +### mod/acl.php + + Addon::callHooks('acl_lookup_end', $results); -mod/friendica.php: Addon::callHooks('about_hook', $o); -mod/subthread.php: Addon::callHooks('post_local_end', $arr); +### mod/network.php + + Addon::callHooks('network_content_init', $arr); + Addon::callHooks('network_tabs', $arr); -mod/profiles.php: Addon::callHooks('profile_post', $_POST); -mod/profiles.php: Addon::callHooks('profile_edit', $arr); +### mod/friendica.php + + Addon::callHooks('about_hook', $o); + +### mod/subthread.php + + Addon::callHooks('post_local_end', $arr); -mod/settings.php: Addon::callHooks('addon_settings_post', $_POST); -mod/settings.php: Addon::callHooks('connector_settings_post', $_POST); -mod/settings.php: Addon::callHooks('display_settings_post', $_POST); -mod/settings.php: Addon::callHooks('settings_post', $_POST); -mod/settings.php: Addon::callHooks('addon_settings', $settings_addons); -mod/settings.php: Addon::callHooks('connector_settings', $settings_connectors); -mod/settings.php: Addon::callHooks('display_settings', $o); -mod/settings.php: Addon::callHooks('settings_form', $o); +### mod/profiles.php + + Addon::callHooks('profile_post', $_POST); + Addon::callHooks('profile_edit', $arr); -mod/photos.php: Addon::callHooks('photo_post_init', $_POST); -mod/photos.php: Addon::callHooks('photo_post_file', $ret); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', intval($item_id)); -mod/photos.php: Addon::callHooks('photo_upload_form', $ret); +### mod/settings.php + + Addon::callHooks('addon_settings_post', $_POST); + Addon::callHooks('connector_settings_post', $_POST); + Addon::callHooks('display_settings_post', $_POST); + Addon::callHooks('settings_post', $_POST); + Addon::callHooks('addon_settings', $settings_addons); + Addon::callHooks('connector_settings', $settings_connectors); + Addon::callHooks('display_settings', $o); + Addon::callHooks('settings_form', $o); -mod/profile.php: Addon::callHooks('profile_advanced', $o); +### mod/photos.php + + Addon::callHooks('photo_post_init', $_POST); + Addon::callHooks('photo_post_file', $ret); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', intval($item_id)); + Addon::callHooks('photo_upload_form', $ret); -mod/home.php: Addon::callHooks('home_init', $ret); -mod/home.php: Addon::callHooks("home_content", $content); +### mod/profile.php + + Addon::callHooks('profile_advanced', $o); -mod/poke.php: Addon::callHooks('post_local_end', $arr); +### mod/home.php + + Addon::callHooks('home_init', $ret); + Addon::callHooks("home_content", $content); -mod/contacts.php: Addon::callHooks('contact_edit_post', $_POST); -mod/contacts.php: Addon::callHooks('contact_edit', $arr); +### mod/poke.php + + Addon::callHooks('post_local_end', $arr); -mod/tagger.php: Addon::callHooks('post_local_end', $arr); +### mod/contacts.php + + Addon::callHooks('contact_edit_post', $_POST); + Addon::callHooks('contact_edit', $arr); -mod/lockview.php: Addon::callHooks('lockview_content', $item); +### mod/tagger.php + + Addon::callHooks('post_local_end', $arr); -mod/uexport.php: Addon::callHooks('uexport_options', $options); +### mod/lockview.php + + Addon::callHooks('lockview_content', $item); -mod/register.php: Addon::callHooks('register_post', $arr); -mod/register.php: Addon::callHooks('register_form', $arr); +### mod/uexport.php + + Addon::callHooks('uexport_options', $options); -mod/item.php: Addon::callHooks('post_local_start', $_REQUEST); -mod/item.php: Addon::callHooks('post_local', $datarray); -mod/item.php: Addon::callHooks('post_local_end', $datarray); +### mod/register.php + + Addon::callHooks('register_post', $arr); + Addon::callHooks('register_form', $arr); -mod/editpost.php: Addon::callHooks('jot_tool', $jotplugins); +### mod/item.php + + Addon::callHooks('post_local_start', $_REQUEST); + Addon::callHooks('post_local', $datarray); + Addon::callHooks('post_local_end', $datarray); -src/Network/FKOAuth1.php: Addon::callHooks('logged_in', $a->user); +### mod/editpost.php -src/Render/FriendicaSmartyEngine.php: Addon::callHooks("template_vars", $arr); + Addon::callHooks('jot_tool', $jotplugins); -src/Model/Item.php: Addon::callHooks('post_local', $item); -src/Model/Item.php: Addon::callHooks('post_remote', $item); -src/Model/Item.php: Addon::callHooks('post_local_end', $posted_item); -src/Model/Item.php: Addon::callHooks('post_remote_end', $posted_item); -src/Model/Item.php: Addon::callHooks('tagged', $arr); -src/Model/Item.php: Addon::callHooks('post_local_end', $new_item); +### src/Network/FKOAuth1.php + + Addon::callHooks('logged_in', $a->user); -src/Model/Contact.php: Addon::callHooks('contact_photo_menu', $args); -src/Model/Contact.php: Addon::callHooks('follow', $arr); +### src/Render/FriendicaSmartyEngine.php + + Addon::callHooks("template_vars", $arr); -src/Model/Profile.php: Addon::callHooks('profile_sidebar_enter', $profile); -src/Model/Profile.php: Addon::callHooks('profile_sidebar', $arr); -src/Model/Profile.php: Addon::callHooks('profile_tabs', $arr); -src/Model/Profile.php: Addon::callHooks('zrl_init', $arr); +### src/Model/Item.php -src/Model/Event.php: Addon::callHooks('event_updated', $event['id']); -src/Model/Event.php: Addon::callHooks("event_created", $event['id']); + Addon::callHooks('post_local', $item); + Addon::callHooks('post_remote', $item); + Addon::callHooks('post_local_end', $posted_item); + Addon::callHooks('post_remote_end', $posted_item); + Addon::callHooks('tagged', $arr); + Addon::callHooks('post_local_end', $new_item); -src/Model/User.php: Addon::callHooks('register_account', $uid); -src/Model/User.php: Addon::callHooks('remove_user', $user); +### src/Model/Contact.php -src/Content/Text/BBCode.php: Addon::callHooks('bbcode', $text); -src/Content/Text/BBCode.php: Addon::callHooks('bb2diaspora', $text); + Addon::callHooks('contact_photo_menu', $args); + Addon::callHooks('follow', $arr); -src/Content/Text/HTML.php: Addon::callHooks('html2bbcode', $message); +### src/Model/Profile.php -src/Content/Smilies.php: Addon::callHooks('smilie', $params); + Addon::callHooks('profile_sidebar_enter', $profile); + Addon::callHooks('profile_sidebar', $arr); + Addon::callHooks('profile_tabs', $arr); + Addon::callHooks('zrl_init', $arr); -src/Content/Feature.php: Addon::callHooks('isEnabled', $arr); -src/Content/Feature.php: Addon::callHooks('get', $arr); +### src/Model/Event.php + + Addon::callHooks('event_updated', $event['id']); + Addon::callHooks("event_created", $event['id']); -src/Content/ContactSelector.php: Addon::callHooks('network_to_name', $nets); -src/Content/ContactSelector.php: Addon::callHooks('gender_selector', $select); -src/Content/ContactSelector.php: Addon::callHooks('sexpref_selector', $select); -src/Content/ContactSelector.php: Addon::callHooks('marital_selector', $select); +### src/Model/User.php + + Addon::callHooks('register_account', $uid); + Addon::callHooks('remove_user', $user); -src/Content/OEmbed.php: Addon::callHooks('oembed_fetch_url', $embedurl, $j); +### src/Content/Text/BBCode.php + + Addon::callHooks('bbcode', $text); + Addon::callHooks('bb2diaspora', $text); -src/Content/Nav.php: Addon::callHooks('page_header', $a->page['nav']); -src/Content/Nav.php: Addon::callHooks('nav_info', $nav); +### src/Content/Text/HTML.php + + Addon::callHooks('html2bbcode', $message); -src/Worker/Directory.php: Addon::callHooks('globaldir_update', $arr); -src/Worker/Notifier.php: Addon::callHooks('notifier_end', $target_item); -src/Worker/Queue.php: Addon::callHooks('queue_predeliver', $r); -src/Worker/Queue.php: Addon::callHooks('queue_deliver', $params); +### src/Content/Smilies.php + + Addon::callHooks('smilie', $params); -src/Module/Login.php: Addon::callHooks('authenticate', $addon_auth); -src/Module/Login.php: Addon::callHooks('login_hook', $o); -src/Module/Logout.php: Addon::callHooks("logging_out"); +### src/Content/Feature.php + + Addon::callHooks('isEnabled', $arr); + Addon::callHooks('get', $arr); -src/Object/Post.php: Addon::callHooks('render_location', $locate); -src/Object/Post.php: Addon::callHooks('display_item', $arr); +### src/Content/ContactSelector.php + + Addon::callHooks('network_to_name', $nets); + Addon::callHooks('gender_selector', $select); + Addon::callHooks('sexpref_selector', $select); + Addon::callHooks('marital_selector', $select); -src/Core/ACL.php: Addon::callHooks('contact_select_options', $x); -src/Core/ACL.php: Addon::callHooks($a->module.'_pre_'.$selname, $arr); -src/Core/ACL.php: Addon::callHooks($a->module.'_post_'.$selname, $o); -src/Core/ACL.php: Addon::callHooks($a->module.'_pre_'.$selname, $arr); -src/Core/ACL.php: Addon::callHooks($a->module.'_post_'.$selname, $o); -src/Core/ACL.php: Addon::callHooks('jot_networks', $jotnets); +### src/Content/OEmbed.php -src/Core/Worker.php: Addon::callHooks("proc_run", $arr); + Addon::callHooks('oembed_fetch_url', $embedurl, $j); -src/Util/Emailer.php: Addon::callHooks('emailer_send_prepare', $params); -src/Util/Emailer.php: Addon::callHooks("emailer_send", $hookdata); +### src/Content/Nav.php -src/Util/Map.php: Addon::callHooks('generate_map', $arr); -src/Util/Map.php: Addon::callHooks('generate_named_map', $arr); -src/Util/Map.php: Addon::callHooks('Map::getCoordinates', $arr); + Addon::callHooks('page_header', $a->page['nav']); + Addon::callHooks('nav_info', $nav); -src/Util/Network.php: Addon::callHooks('avatar_lookup', $avatar); +### src/Worker/Directory.php + + Addon::callHooks('globaldir_update', $arr); -src/Util/ParseUrl.php: Addon::callHooks("getsiteinfo", $siteinfo); +### src/Worker/Notifier.php + + Addon::callHooks('notifier_end', $target_item); -src/Protocol/DFRN.php: Addon::callHooks('atom_feed_end', $atom); -src/Protocol/DFRN.php: Addon::callHooks('atom_feed_end', $atom); +### src/Worker/Queue.php + + Addon::callHooks('queue_predeliver', $r); + Addon::callHooks('queue_deliver', $params); + +### src/Module/Login.php + + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('login_hook', $o); + +### src/Module/Logout.php + + Addon::callHooks("logging_out"); + +### src/Object/Post.php + + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); + +### src/Core/ACL.php + + Addon::callHooks('contact_select_options', $x); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks('jot_networks', $jotnets); + +### src/Core/Worker.php + + Addon::callHooks("proc_run", $arr); + +### src/Util/Emailer.php + + Addon::callHooks('emailer_send_prepare', $params); + Addon::callHooks("emailer_send", $hookdata); + +### src/Util/Map.php + + Addon::callHooks('generate_map', $arr); + Addon::callHooks('generate_named_map', $arr); + Addon::callHooks('Map::getCoordinates', $arr); + +### src/Util/Network.php + + Addon::callHooks('avatar_lookup', $avatar); + +### src/Util/ParseUrl.php + + Addon::callHooks("getsiteinfo", $siteinfo); + +### src/Protocol/DFRN.php + + Addon::callHooks('atom_feed_end', $atom); + Addon::callHooks('atom_feed_end', $atom); From 81d636d05d931655d45f11a3a64d15d707e4286f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Tue, 24 Apr 2018 13:20:44 +0200 Subject: [PATCH 03/10] [DOCS] Titles: Fix spaces --- doc/Chats.md | 4 ++-- doc/Improve-Performance.md | 10 +++++----- doc/Installing-Connectors.md | 6 +++--- doc/Making-Friends.md | 8 ++++---- doc/de/Chats.md | 4 ++-- doc/de/Improve-Performance.md | 10 +++++----- 6 files changed, 21 insertions(+), 21 deletions(-) diff --git a/doc/Chats.md b/doc/Chats.md index b7557944f..29067e128 100644 --- a/doc/Chats.md +++ b/doc/Chats.md @@ -37,7 +37,7 @@ You can use several servers to create an account: * [https://jappix.com](https://jappix.com) * [http://xmpp.net](http://xmpp.net) -###1. Basics +### 1. Basics At first you have to get the current version. You can either pull it from [Github](https://github.com) like so: @@ -54,7 +54,7 @@ The following page shows the settings of this addon. Activate the BOSH proxy. -###2. Settings +### 2. Settings Go to your user account settings next and choose the addon page. Scroll down until you find the Jappix Mini addon settings. diff --git a/doc/Improve-Performance.md b/doc/Improve-Performance.md index 48ac9e798..79490c257 100644 --- a/doc/Improve-Performance.md +++ b/doc/Improve-Performance.md @@ -29,7 +29,7 @@ Active the following addons: rendertime -###rendertime +### rendertime This addon doesn't speed up your system. It helps to analyze your bottlenecks. @@ -52,7 +52,7 @@ Apache Webserver The following Apache modules are recommended: -###Cache-Control +### Cache-Control This module tells the client to cache the content of static files so that they aren't fetched with every request. Enable the module "mod_expires" by typing in "a2enmod expires" as root. @@ -62,7 +62,7 @@ Please add the following lines to your site configuration in the "directory" con Also see the Apache [2.2](http://httpd.apache.org/docs/2.2/mod/mod_expires.html) / [2.4](https://httpd.apache.org/docs/2.4/mod/mod_expires.html) documentation. -###Compress content +### Compress content This module compresses the traffic between the web server and the client. Enable the module "mod_deflate" by typing in "a2enmod deflate" as root. @@ -72,14 +72,14 @@ Also see the Apache [2.2](http://httpd.apache.org/docs/2.2/mod/mod_deflate.html) PHP -------- -###FCGI +### FCGI When using Apache think about using FCGI. In a Debian-based distribution you will need to install the packages named "php5-cgi" and "libapache2-mod-fcgid". Please refer to external documentation for a more detailed explanation how to set up a system based upon FCGI. -###Database +### Database There are scripts like [tuning-primer.sh](http://www.day32.com/MySQL/) and [mysqltuner.pl](http://mysqltuner.pl) that analyze your database server and give hints on values that could be changed. diff --git a/doc/Installing-Connectors.md b/doc/Installing-Connectors.md index 1d83f0742..5ea34d473 100644 --- a/doc/Installing-Connectors.md +++ b/doc/Installing-Connectors.md @@ -32,7 +32,7 @@ Twitter Addon for Friendica * tobias.diekershoff@gmx.net * License: 3-clause BSD license -###Configuration +### Configuration To use this addon you need a OAuth Consumer key pair (key & secret). You can get it from [Twitter](https://twitter.com/apps). @@ -46,7 +46,7 @@ Add this key pair to your global .htconfig.php: After this, your users can configure their Twitter account settings from "Settings -> Connector Settings". -###More documentation +### More documentation Find the author's documentation here: [http://diekershoff.homeunix.net/redmine/wiki/friendikaplugin/Twitter_Plugin](http://diekershoff.homeunix.net/redmine/wiki/friendikaplugin/Twitter_Plugin) @@ -58,7 +58,7 @@ GNU Social Addon for Friendica * tobias.diekershoff@gmx.net * License: 3-clause BSD license -###Configuration +### Configuration When the addon is activated the user has to acquire the following in order to connect to the GNU Social account of choice. diff --git a/doc/Making-Friends.md b/doc/Making-Friends.md index d7f18298c..e435dc7a4 100644 --- a/doc/Making-Friends.md +++ b/doc/Making-Friends.md @@ -50,7 +50,7 @@ This will take you through a similar process. Connect to users of alternate networks --- -###Across the Federation and Fedivese +### Across the Federation and Fedivese You can also use your Identity Address or other people's Identity Addresses to become friends across the so-called Federation/Fedivese of open source social media. Currently, Friendica supports connections with people on diaspora*, Red, Hubzilla, GNU Social, StatusNet, Mastodon, Pleroma, socialhome, and ganggo platforms. @@ -60,13 +60,13 @@ Note: Some versions of GNU Social software may require the full URL to your prof People on these networks can also initiate contact with you, if they know your contact details. -###Other social media +### Other social media If you server provides this functionality, you can also connect with people one Twitter or important feeds from Tumblr, Wordpress, and many more. To connect, enter their contact details in the "connect" box on your "Contacts" page. -###Email +### Email If you have supplied your mailbox connection information on your Settings page, you can enter the email address of anybody that has sent you a message recently and have their email messages show up in your social stream. You can also reply to them from within Friendica. @@ -76,7 +76,7 @@ In order to avoid abuse or spam, you must have an email from Alice with the corr Subscribing to mailing lists is done in the same way, but without the use of the "mailto:" prefix. To subscribe to a mailing list, enter the email in following example format "mailling-list@list-server.net". -###Syndication feeds +### Syndication feeds You can "follow" almost anybody or any website that produces a syndication feed (RSS/Atom,etc.). If we can find an information stream and a name to attach to the contact, we'll try to connect with them. diff --git a/doc/de/Chats.md b/doc/de/Chats.md index fc46af650..77dfdeb44 100644 --- a/doc/de/Chats.md +++ b/doc/de/Chats.md @@ -8,7 +8,7 @@ Du hast derzeit zwei Möglichkeiten, einen Chat auf Deiner Friendica-Seite zu be * IRC - Internet Relay Chat * Jappix -##IRC Addon +## IRC Addon Sobald das Addon aktiviert ist, kannst Du den Chat unter [deineSeite.de/irc](../irc) finden. Beachte aber, dass dieser Chat auch ohne Anmeldung auf Deiner Seite zugänglich ist und somit auch Fremde diesen Chat mitnutzen können. @@ -27,7 +27,7 @@ Unten hast Du ein Eingabefeld, um Beiträge zu schreiben. Weiter Informationen zu IRC findest Du zum Beispiel auf ubuntuusers.de, in Wikipedia oder bei icrhelp.org (in Englisch). -##Jappix Mini +## Jappix Mini Das Jappix Mini Addon erlaubt das Erstellen einer Chatbox für Jabber/XMPP-Kontakte. Ein Jabber/XMPP Account sollte vor der Installation bereits vorhanden sein. diff --git a/doc/de/Improve-Performance.md b/doc/de/Improve-Performance.md index c1f0a54fa..d9be4fca6 100644 --- a/doc/de/Improve-Performance.md +++ b/doc/de/Improve-Performance.md @@ -35,7 +35,7 @@ Aktiviere die folgenden Addons: rendertime -###rendertime +### rendertime **Beschreibung** @@ -60,7 +60,7 @@ Webserver Wenn du einen Apache-Webserver nutzt, aktiviere bitte die folgenden Module: -###Cache-Control +### Cache-Control **Beschreibung** @@ -74,7 +74,7 @@ ExpiresActive on ExpiresDefault "access plus 1 week" Weitere Informationen findest du hier: http://httpd.apache.org/docs/2.2/mod/mod_expires.html. -###Compress content +### Compress content **Beschreibung** @@ -85,7 +85,7 @@ Aktiviere das Modul "mod_deflate" durch die Eingabe "a2enmod deflate" als root. Weitere Informationen findest du hier: http://httpd.apache.org/docs/2.2/mod/mod_deflate.html -###PHP +### PHP **FCGI** @@ -93,7 +93,7 @@ Wenn du Apache nutzt, dann denk darüber nach, FCGI zu nutzen. Wenn du eine Debian-basierte Distribution nutzt, dann wirst du die Pakete "php5-cgi" und "libapache2-mod-fcgid" benötigen. Nutze externe Dokumente, um eine detailiertere Erklärung für die Einrichtung eines Systems auf FCGI-Basis zu erhalten. -###Database +### Database Es gibt Skripte wie [tuning-primer.sh](http://www.day32.com/MySQL/) und [mysqltuner.pl](http://mysqltuner.pl), die den Datenbankserver analysieren und Hinweise darauf geben, welche Werte verändert werden könnten. From 7ac4b17c8075a268247a19e4ecb538dbbaa3af63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Tue, 24 Apr 2018 13:21:16 +0200 Subject: [PATCH 04/10] [DOCS] Hooks: Add empty line --- doc/Addons.md | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/Addons.md b/doc/Addons.md index 221c68a81..78f5f8b78 100644 --- a/doc/Addons.md +++ b/doc/Addons.md @@ -335,6 +335,7 @@ Here is a complete list of all hook callbacks with file locations (as of 01-Apr- Addon::callHooks('page_end', $a->page['content']); ### include/api.php + Addon::callHooks('logged_in', $a->user); Addon::callHooks('authenticate', $addon_auth); Addon::callHooks('logged_in', $a->user); From 008f2a2ec772fd5a733f56c01f0d8a86ea9b85d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Tue, 24 Apr 2018 13:25:06 +0200 Subject: [PATCH 05/10] [DOCS] Hooks: Add hooks intendation to german docs --- doc/de/Addons.md | 376 +++++++++++++++++++++++++++++++---------------- 1 file changed, 246 insertions(+), 130 deletions(-) diff --git a/doc/de/Addons.md b/doc/de/Addons.md index 7651840f4..affc4ba2b 100644 --- a/doc/de/Addons.md +++ b/doc/de/Addons.md @@ -191,184 +191,300 @@ Komplette Liste der Hook-Callbacks Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Apr-2018 generiert): Bitte schau in die Quellcodes für Details zu Hooks, die oben nicht dokumentiert sind. -index.php: Addon::callHooks('init_1'); -index.php: Addon::callHooks('app_menu', $arr); -index.php: Addon::callHooks('page_content_top', $a->page['content']); -index.php: Addon::callHooks($a->module.'_mod_init', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_init', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_post', $_POST); -index.php: Addon::callHooks($a->module.'_mod_afterpost', $placeholder); -index.php: Addon::callHooks($a->module.'_mod_content', $arr); -index.php: Addon::callHooks($a->module.'_mod_aftercontent', $arr); -index.php: Addon::callHooks('page_end', $a->page['content']); +### index.php -include/api.php: Addon::callHooks('logged_in', $a->user); -include/api.php: Addon::callHooks('authenticate', $addon_auth); -include/api.php: Addon::callHooks('logged_in', $a->user); + Addon::callHooks('init_1'); + Addon::callHooks('app_menu', $arr); + Addon::callHooks('page_content_top', $a->page['content']); + Addon::callHooks($a->module.'_mod_init', $placeholder); + Addon::callHooks($a->module.'_mod_init', $placeholder); + Addon::callHooks($a->module.'_mod_post', $_POST); + Addon::callHooks($a->module.'_mod_afterpost', $placeholder); + Addon::callHooks($a->module.'_mod_content', $arr); + Addon::callHooks($a->module.'_mod_aftercontent', $arr); + Addon::callHooks('page_end', $a->page['content']); + +### include/api.php -include/enotify.php: Addon::callHooks('enotify', $h); -include/enotify.php: Addon::callHooks('enotify_store', $datarray); -include/enotify.php: Addon::callHooks('enotify_mail', $datarray); -include/enotify.php: Addon::callHooks('check_item_notification', $notification_data); + Addon::callHooks('logged_in', $a->user); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('logged_in', $a->user); -include/conversation.php: Addon::callHooks('conversation_start', $cb); -include/conversation.php: Addon::callHooks('render_location', $locate); -include/conversation.php: Addon::callHooks('display_item', $arr); -include/conversation.php: Addon::callHooks('display_item', $arr); -include/conversation.php: Addon::callHooks('item_photo_menu', $args); -include/conversation.php: Addon::callHooks('jot_tool', $jotplugins); +### include/enotify.php + + Addon::callHooks('enotify', $h); + Addon::callHooks('enotify_store', $datarray); + Addon::callHooks('enotify_mail', $datarray); + Addon::callHooks('check_item_notification', $notification_data); + +### include/conversation.php -include/security.php: Addon::callHooks('logged_in', $a->user); + Addon::callHooks('conversation_start', $cb); + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); + Addon::callHooks('display_item', $arr); + Addon::callHooks('item_photo_menu', $args); + Addon::callHooks('jot_tool', $jotplugins); -include/text.php: Addon::callHooks('contact_block_end', $arr); -include/text.php: Addon::callHooks('poke_verbs', $arr); -include/text.php: Addon::callHooks('prepare_body_init', $item); -include/text.php: Addon::callHooks('prepare_body_content_filter', $hook_data); -include/text.php: Addon::callHooks('prepare_body', $hook_data); -include/text.php: Addon::callHooks('prepare_body_final', $hook_data); +### include/security.php + + Addon::callHooks('logged_in', $a->user); -include/items.php: Addon::callHooks('page_info_data', $data); +### include/text.php -mod/directory.php: Addon::callHooks('directory_item', $arr); + Addon::callHooks('contact_block_end', $arr); + Addon::callHooks('poke_verbs', $arr); + Addon::callHooks('prepare_body_init', $item); + Addon::callHooks('prepare_body_content_filter', $hook_data); + Addon::callHooks('prepare_body', $hook_data); + Addon::callHooks('prepare_body_final', $hook_data); -mod/xrd.php: Addon::callHooks('personal_xrd', $arr); +### include/items.php + + Addon::callHooks('page_info_data', $data); -mod/ping.php: Addon::callHooks('network_ping', $arr); +### mod/directory.php + + Addon::callHooks('directory_item', $arr); -mod/parse_url.php: Addon::callHooks("parse_link", $arr); +### mod/xrd.php + + Addon::callHooks('personal_xrd', $arr); -mod/manage.php: Addon::callHooks('home_init', $ret); +### mod/ping.php + + Addon::callHooks('network_ping', $arr); -mod/acl.php: Addon::callHooks('acl_lookup_end', $results); +### mod/parse_url.php + + Addon::callHooks("parse_link", $arr); -mod/network.php: Addon::callHooks('network_content_init', $arr); -mod/network.php: Addon::callHooks('network_tabs', $arr); +### mod/manage.php + + Addon::callHooks('home_init', $ret); -mod/friendica.php: Addon::callHooks('about_hook', $o); -mod/subthread.php: Addon::callHooks('post_local_end', $arr); +### mod/acl.php + + Addon::callHooks('acl_lookup_end', $results); -mod/profiles.php: Addon::callHooks('profile_post', $_POST); -mod/profiles.php: Addon::callHooks('profile_edit', $arr); +### mod/network.php + + Addon::callHooks('network_content_init', $arr); + Addon::callHooks('network_tabs', $arr); -mod/settings.php: Addon::callHooks('addon_settings_post', $_POST); -mod/settings.php: Addon::callHooks('connector_settings_post', $_POST); -mod/settings.php: Addon::callHooks('display_settings_post', $_POST); -mod/settings.php: Addon::callHooks('settings_post', $_POST); -mod/settings.php: Addon::callHooks('addon_settings', $settings_addons); -mod/settings.php: Addon::callHooks('connector_settings', $settings_connectors); -mod/settings.php: Addon::callHooks('display_settings', $o); -mod/settings.php: Addon::callHooks('settings_form', $o); +### mod/friendica.php + + Addon::callHooks('about_hook', $o); + +### mod/subthread.php + + Addon::callHooks('post_local_end', $arr); -mod/photos.php: Addon::callHooks('photo_post_init', $_POST); -mod/photos.php: Addon::callHooks('photo_post_file', $ret); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', $foo); -mod/photos.php: Addon::callHooks('photo_post_end', intval($item_id)); -mod/photos.php: Addon::callHooks('photo_upload_form', $ret); +### mod/profiles.php + + Addon::callHooks('profile_post', $_POST); + Addon::callHooks('profile_edit', $arr); -mod/profile.php: Addon::callHooks('profile_advanced', $o); +### mod/settings.php + + Addon::callHooks('addon_settings_post', $_POST); + Addon::callHooks('connector_settings_post', $_POST); + Addon::callHooks('display_settings_post', $_POST); + Addon::callHooks('settings_post', $_POST); + Addon::callHooks('addon_settings', $settings_addons); + Addon::callHooks('connector_settings', $settings_connectors); + Addon::callHooks('display_settings', $o); + Addon::callHooks('settings_form', $o); -mod/home.php: Addon::callHooks('home_init', $ret); -mod/home.php: Addon::callHooks("home_content", $content); +### mod/photos.php + + Addon::callHooks('photo_post_init', $_POST); + Addon::callHooks('photo_post_file', $ret); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', intval($item_id)); + Addon::callHooks('photo_upload_form', $ret); -mod/poke.php: Addon::callHooks('post_local_end', $arr); +### mod/profile.php + + Addon::callHooks('profile_advanced', $o); -mod/contacts.php: Addon::callHooks('contact_edit_post', $_POST); -mod/contacts.php: Addon::callHooks('contact_edit', $arr); +### mod/home.php + + Addon::callHooks('home_init', $ret); + Addon::callHooks("home_content", $content); -mod/tagger.php: Addon::callHooks('post_local_end', $arr); +### mod/poke.php + + Addon::callHooks('post_local_end', $arr); -mod/lockview.php: Addon::callHooks('lockview_content', $item); +### mod/contacts.php + + Addon::callHooks('contact_edit_post', $_POST); + Addon::callHooks('contact_edit', $arr); -mod/uexport.php: Addon::callHooks('uexport_options', $options); +### mod/tagger.php + + Addon::callHooks('post_local_end', $arr); -mod/register.php: Addon::callHooks('register_post', $arr); -mod/register.php: Addon::callHooks('register_form', $arr); +### mod/lockview.php + + Addon::callHooks('lockview_content', $item); -mod/item.php: Addon::callHooks('post_local_start', $_REQUEST); -mod/item.php: Addon::callHooks('post_local', $datarray); -mod/item.php: Addon::callHooks('post_local_end', $datarray); +### mod/uexport.php + + Addon::callHooks('uexport_options', $options); -mod/editpost.php: Addon::callHooks('jot_tool', $jotplugins); +### mod/register.php + + Addon::callHooks('register_post', $arr); + Addon::callHooks('register_form', $arr); -src/Network/FKOAuth1.php: Addon::callHooks('logged_in', $a->user); +### mod/item.php + + Addon::callHooks('post_local_start', $_REQUEST); + Addon::callHooks('post_local', $datarray); + Addon::callHooks('post_local_end', $datarray); -src/Render/FriendicaSmartyEngine.php: Addon::callHooks("template_vars", $arr); +### mod/editpost.php -src/Model/Item.php: Addon::callHooks('post_local', $item); -src/Model/Item.php: Addon::callHooks('post_remote', $item); -src/Model/Item.php: Addon::callHooks('post_local_end', $posted_item); -src/Model/Item.php: Addon::callHooks('post_remote_end', $posted_item); -src/Model/Item.php: Addon::callHooks('tagged', $arr); -src/Model/Item.php: Addon::callHooks('post_local_end', $new_item); + Addon::callHooks('jot_tool', $jotplugins); -src/Model/Contact.php: Addon::callHooks('contact_photo_menu', $args); -src/Model/Contact.php: Addon::callHooks('follow', $arr); +### src/Network/FKOAuth1.php + + Addon::callHooks('logged_in', $a->user); -src/Model/Profile.php: Addon::callHooks('profile_sidebar_enter', $profile); -src/Model/Profile.php: Addon::callHooks('profile_sidebar', $arr); -src/Model/Profile.php: Addon::callHooks('profile_tabs', $arr); -src/Model/Profile.php: Addon::callHooks('zrl_init', $arr); +### src/Render/FriendicaSmartyEngine.php + + Addon::callHooks("template_vars", $arr); -src/Model/Event.php: Addon::callHooks('event_updated', $event['id']); -src/Model/Event.php: Addon::callHooks("event_created", $event['id']); +### src/Model/Item.php -src/Model/User.php: Addon::callHooks('register_account', $uid); -src/Model/User.php: Addon::callHooks('remove_user', $user); + Addon::callHooks('post_local', $item); + Addon::callHooks('post_remote', $item); + Addon::callHooks('post_local_end', $posted_item); + Addon::callHooks('post_remote_end', $posted_item); + Addon::callHooks('tagged', $arr); + Addon::callHooks('post_local_end', $new_item); -src/Content/Text/BBCode.php: Addon::callHooks('bbcode', $text); -src/Content/Text/BBCode.php: Addon::callHooks('bb2diaspora', $text); +### src/Model/Contact.php -src/Content/Text/HTML.php: Addon::callHooks('html2bbcode', $message); + Addon::callHooks('contact_photo_menu', $args); + Addon::callHooks('follow', $arr); -src/Content/Smilies.php: Addon::callHooks('smilie', $params); +### src/Model/Profile.php -src/Content/Feature.php: Addon::callHooks('isEnabled', $arr); -src/Content/Feature.php: Addon::callHooks('get', $arr); + Addon::callHooks('profile_sidebar_enter', $profile); + Addon::callHooks('profile_sidebar', $arr); + Addon::callHooks('profile_tabs', $arr); + Addon::callHooks('zrl_init', $arr); -src/Content/ContactSelector.php: Addon::callHooks('network_to_name', $nets); -src/Content/ContactSelector.php: Addon::callHooks('gender_selector', $select); -src/Content/ContactSelector.php: Addon::callHooks('sexpref_selector', $select); -src/Content/ContactSelector.php: Addon::callHooks('marital_selector', $select); +### src/Model/Event.php + + Addon::callHooks('event_updated', $event['id']); + Addon::callHooks("event_created", $event['id']); -src/Content/OEmbed.php: Addon::callHooks('oembed_fetch_url', $embedurl, $j); +### src/Model/User.php + + Addon::callHooks('register_account', $uid); + Addon::callHooks('remove_user', $user); -src/Content/Nav.php: Addon::callHooks('page_header', $a->page['nav']); -src/Content/Nav.php: Addon::callHooks('nav_info', $nav); +### src/Content/Text/BBCode.php + + Addon::callHooks('bbcode', $text); + Addon::callHooks('bb2diaspora', $text); -src/Worker/Directory.php: Addon::callHooks('globaldir_update', $arr); -src/Worker/Notifier.php: Addon::callHooks('notifier_end', $target_item); -src/Worker/Queue.php: Addon::callHooks('queue_predeliver', $r); -src/Worker/Queue.php: Addon::callHooks('queue_deliver', $params); +### src/Content/Text/HTML.php + + Addon::callHooks('html2bbcode', $message); -src/Module/Login.php: Addon::callHooks('authenticate', $addon_auth); -src/Module/Login.php: Addon::callHooks('login_hook', $o); -src/Module/Logout.php: Addon::callHooks("logging_out"); +### src/Content/Smilies.php + + Addon::callHooks('smilie', $params); -src/Object/Post.php: Addon::callHooks('render_location', $locate); -src/Object/Post.php: Addon::callHooks('display_item', $arr); +### src/Content/Feature.php + + Addon::callHooks('isEnabled', $arr); + Addon::callHooks('get', $arr); -src/Core/ACL.php: Addon::callHooks('contact_select_options', $x); -src/Core/ACL.php: Addon::callHooks($a->module.'_pre_'.$selname, $arr); -src/Core/ACL.php: Addon::callHooks($a->module.'_post_'.$selname, $o); -src/Core/ACL.php: Addon::callHooks($a->module.'_pre_'.$selname, $arr); -src/Core/ACL.php: Addon::callHooks($a->module.'_post_'.$selname, $o); -src/Core/ACL.php: Addon::callHooks('jot_networks', $jotnets); +### src/Content/ContactSelector.php + + Addon::callHooks('network_to_name', $nets); + Addon::callHooks('gender_selector', $select); + Addon::callHooks('sexpref_selector', $select); + Addon::callHooks('marital_selector', $select); -src/Core/Worker.php: Addon::callHooks("proc_run", $arr); +### src/Content/OEmbed.php -src/Util/Emailer.php: Addon::callHooks('emailer_send_prepare', $params); -src/Util/Emailer.php: Addon::callHooks("emailer_send", $hookdata); + Addon::callHooks('oembed_fetch_url', $embedurl, $j); -src/Util/Map.php: Addon::callHooks('generate_map', $arr); -src/Util/Map.php: Addon::callHooks('generate_named_map', $arr); -src/Util/Map.php: Addon::callHooks('Map::getCoordinates', $arr); +### src/Content/Nav.php -src/Util/Network.php: Addon::callHooks('avatar_lookup', $avatar); + Addon::callHooks('page_header', $a->page['nav']); + Addon::callHooks('nav_info', $nav); -src/Util/ParseUrl.php: Addon::callHooks("getsiteinfo", $siteinfo); +### src/Worker/Directory.php + + Addon::callHooks('globaldir_update', $arr); -src/Protocol/DFRN.php: Addon::callHooks('atom_feed_end', $atom); -src/Protocol/DFRN.php: Addon::callHooks('atom_feed_end', $atom); +### src/Worker/Notifier.php + + Addon::callHooks('notifier_end', $target_item); + +### src/Worker/Queue.php + + Addon::callHooks('queue_predeliver', $r); + Addon::callHooks('queue_deliver', $params); + +### src/Module/Login.php + + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('login_hook', $o); + +### src/Module/Logout.php + + Addon::callHooks("logging_out"); + +### src/Object/Post.php + + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); + +### src/Core/ACL.php + + Addon::callHooks('contact_select_options', $x); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks('jot_networks', $jotnets); + +### src/Core/Worker.php + + Addon::callHooks("proc_run", $arr); + +### src/Util/Emailer.php + + Addon::callHooks('emailer_send_prepare', $params); + Addon::callHooks("emailer_send", $hookdata); + +### src/Util/Map.php + + Addon::callHooks('generate_map', $arr); + Addon::callHooks('generate_named_map', $arr); + Addon::callHooks('Map::getCoordinates', $arr); + +### src/Util/Network.php + + Addon::callHooks('avatar_lookup', $avatar); + +### src/Util/ParseUrl.php + + Addon::callHooks("getsiteinfo", $siteinfo); + +### src/Protocol/DFRN.php + + Addon::callHooks('atom_feed_end', $atom); + Addon::callHooks('atom_feed_end', $atom); From ce52f40bdc1cf0b6491879be7b30eff17bb8f7cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20M=C3=BCller?= <25648755+M-arcus@users.noreply.github.com> Date: Wed, 25 Apr 2018 11:29:56 +0200 Subject: [PATCH 06/10] [DOCS] Fix intendation --- doc/Addons.md | 330 +++++++++++++++++++++++------------------------ doc/de/Addons.md | 294 ++++++++++++++++++++--------------------- 2 files changed, 312 insertions(+), 312 deletions(-) diff --git a/doc/Addons.md b/doc/Addons.md index 78f5f8b78..f7d93aac7 100644 --- a/doc/Addons.md +++ b/doc/Addons.md @@ -126,8 +126,8 @@ $b contains the $a->user array. 'display_item' is called when formatting a post for display. $b is an array: - 'item' => The item (array) details pulled from the database - 'output' => the (string) HTML representation of this item prior to adding it to the page + 'item' => The item (array) details pulled from the database + 'output' => the (string) HTML representation of this item prior to adding it to the page ### 'post_local' * called when a status post or comment is entered on the local system @@ -167,8 +167,8 @@ $b is an array: 'profile_edit' is called prior to output of profile edit page. $b is an array containing: - 'profile' => profile (array) record from the database - 'entry' => the (string) HTML of the generated entry + 'profile' => profile (array) record from the database + 'entry' => the (string) HTML of the generated entry ### 'profile_advanced' * called when the HTML is generated for the 'Advanced profile', corresponding to the 'Profile' tab within a person's profile page @@ -179,7 +179,7 @@ $b is an array containing: 'directory_item' is called from the Directory page when formatting an item for display. $b is an array: - 'contact' => contact (array) record for the person from the database + 'contact' => contact (array) record for the person from the database 'entry' => the (string) HTML of the generated entry ### 'profile_sidebar_enter' @@ -190,15 +190,15 @@ $b is an array: 'profile_sidebar is called when generating the sidebar "short" profile for a page. $b is an array: - 'profile' => profile (array) record for the person from the database - 'entry' => the (string) HTML of the generated entry + 'profile' => profile (array) record for the person from the database + 'entry' => the (string) HTML of the generated entry ### 'contact_block_end' is called when formatting the block of contacts/friends on a profile sidebar has completed. $b is an array: - 'contacts' => array of contacts - 'output' => the (string) generated HTML of the contact block + 'contacts' => array of contacts + 'output' => the (string) generated HTML of the contact block ### 'bbcode' * called during conversion of bbcode to html @@ -216,8 +216,8 @@ $b is an array: 'personal_xrd' is called prior to output of personal XRD file. $b is an array: - 'user' => the user record for the person - 'xml' => the complete XML to be output + 'user' => the user record for the person + 'xml' => the complete XML to be output ### 'home_content' * called prior to output home page content, shown to unlogged users @@ -227,8 +227,8 @@ $b is an array: is called when editing contact details on an individual from the Contacts page. $b is an array: - 'contact' => contact record (array) of target contact - 'output' => the (string) generated HTML of the contact edit page + 'contact' => contact record (array) of target contact + 'output' => the (string) generated HTML of the contact edit page ### 'contact_edit_post' * called when posting the contact edit page. @@ -246,9 +246,9 @@ $b is an array: 'avatar_lookup' is called when looking up the avatar. $b is an array: - 'size' => the size of the avatar that will be looked up - 'email' => email to look up the avatar for - 'url' => the (string) generated URL of the avatar + 'size' => the size of the avatar that will be looked up + 'email' => email to look up the avatar for + 'url' => the (string) generated URL of the avatar ### 'emailer_send_prepare' 'emailer_send_prepare' called from Emailer::send() before building the mime message. @@ -306,15 +306,15 @@ Hook data: Called after the HTML conversion in prepare_body. Hook data: 'item' => item array (input) - 'html' => converted item body (input/output) - 'is_preview' => post preview flag (input) + 'html' => converted item body (input/output) + 'is_preview' => post preview flag (input) 'filter_reasons' => reasons array (input) ### 'prepare_body_final' Called at the end of prepare_body. Hook data: 'item' => item array (input) - 'html' => converted item body (input/output) + 'html' => converted item body (input/output) Complete list of hook callbacks --- @@ -336,12 +336,12 @@ Here is a complete list of all hook callbacks with file locations (as of 01-Apr- ### include/api.php - Addon::callHooks('logged_in', $a->user); - Addon::callHooks('authenticate', $addon_auth); - Addon::callHooks('logged_in', $a->user); + Addon::callHooks('logged_in', $a->user); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('logged_in', $a->user); ### include/enotify.php - + Addon::callHooks('enotify', $h); Addon::callHooks('enotify_store', $datarray); Addon::callHooks('enotify_mail', $datarray); @@ -357,8 +357,8 @@ Here is a complete list of all hook callbacks with file locations (as of 01-Apr- Addon::callHooks('jot_tool', $jotplugins); ### include/security.php - - Addon::callHooks('logged_in', $a->user); + + Addon::callHooks('logged_in', $a->user); ### include/text.php @@ -370,251 +370,251 @@ Here is a complete list of all hook callbacks with file locations (as of 01-Apr- Addon::callHooks('prepare_body_final', $hook_data); ### include/items.php - - Addon::callHooks('page_info_data', $data); + + Addon::callHooks('page_info_data', $data); ### mod/directory.php - - Addon::callHooks('directory_item', $arr); + + Addon::callHooks('directory_item', $arr); ### mod/xrd.php - - Addon::callHooks('personal_xrd', $arr); + + Addon::callHooks('personal_xrd', $arr); ### mod/ping.php - - Addon::callHooks('network_ping', $arr); + + Addon::callHooks('network_ping', $arr); ### mod/parse_url.php - - Addon::callHooks("parse_link", $arr); + + Addon::callHooks("parse_link", $arr); ### mod/manage.php - - Addon::callHooks('home_init', $ret); + + Addon::callHooks('home_init', $ret); ### mod/acl.php - - Addon::callHooks('acl_lookup_end', $results); + + Addon::callHooks('acl_lookup_end', $results); ### mod/network.php - - Addon::callHooks('network_content_init', $arr); - Addon::callHooks('network_tabs', $arr); + + Addon::callHooks('network_content_init', $arr); + Addon::callHooks('network_tabs', $arr); ### mod/friendica.php - - Addon::callHooks('about_hook', $o); - + + Addon::callHooks('about_hook', $o); + ### mod/subthread.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/profiles.php - - Addon::callHooks('profile_post', $_POST); - Addon::callHooks('profile_edit', $arr); + + Addon::callHooks('profile_post', $_POST); + Addon::callHooks('profile_edit', $arr); ### mod/settings.php - - Addon::callHooks('addon_settings_post', $_POST); - Addon::callHooks('connector_settings_post', $_POST); - Addon::callHooks('display_settings_post', $_POST); - Addon::callHooks('settings_post', $_POST); - Addon::callHooks('addon_settings', $settings_addons); - Addon::callHooks('connector_settings', $settings_connectors); - Addon::callHooks('display_settings', $o); - Addon::callHooks('settings_form', $o); + + Addon::callHooks('addon_settings_post', $_POST); + Addon::callHooks('connector_settings_post', $_POST); + Addon::callHooks('display_settings_post', $_POST); + Addon::callHooks('settings_post', $_POST); + Addon::callHooks('addon_settings', $settings_addons); + Addon::callHooks('connector_settings', $settings_connectors); + Addon::callHooks('display_settings', $o); + Addon::callHooks('settings_form', $o); ### mod/photos.php - - Addon::callHooks('photo_post_init', $_POST); - Addon::callHooks('photo_post_file', $ret); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', intval($item_id)); - Addon::callHooks('photo_upload_form', $ret); + + Addon::callHooks('photo_post_init', $_POST); + Addon::callHooks('photo_post_file', $ret); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', intval($item_id)); + Addon::callHooks('photo_upload_form', $ret); ### mod/profile.php - - Addon::callHooks('profile_advanced', $o); + + Addon::callHooks('profile_advanced', $o); ### mod/home.php - - Addon::callHooks('home_init', $ret); - Addon::callHooks("home_content", $content); + + Addon::callHooks('home_init', $ret); + Addon::callHooks("home_content", $content); ### mod/poke.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/contacts.php - - Addon::callHooks('contact_edit_post', $_POST); - Addon::callHooks('contact_edit', $arr); + + Addon::callHooks('contact_edit_post', $_POST); + Addon::callHooks('contact_edit', $arr); ### mod/tagger.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/lockview.php - - Addon::callHooks('lockview_content', $item); + + Addon::callHooks('lockview_content', $item); ### mod/uexport.php - - Addon::callHooks('uexport_options', $options); + + Addon::callHooks('uexport_options', $options); ### mod/register.php - - Addon::callHooks('register_post', $arr); - Addon::callHooks('register_form', $arr); + + Addon::callHooks('register_post', $arr); + Addon::callHooks('register_form', $arr); ### mod/item.php - - Addon::callHooks('post_local_start', $_REQUEST); - Addon::callHooks('post_local', $datarray); - Addon::callHooks('post_local_end', $datarray); -### mod/editpost.php + Addon::callHooks('post_local_start', $_REQUEST); + Addon::callHooks('post_local', $datarray); + Addon::callHooks('post_local_end', $datarray); + +### mod/editpost.php Addon::callHooks('jot_tool', $jotplugins); ### src/Network/FKOAuth1.php - - Addon::callHooks('logged_in', $a->user); + + Addon::callHooks('logged_in', $a->user); ### src/Render/FriendicaSmartyEngine.php - - Addon::callHooks("template_vars", $arr); + + Addon::callHooks("template_vars", $arr); ### src/Model/Item.php - Addon::callHooks('post_local', $item); - Addon::callHooks('post_remote', $item); - Addon::callHooks('post_local_end', $posted_item); - Addon::callHooks('post_remote_end', $posted_item); - Addon::callHooks('tagged', $arr); - Addon::callHooks('post_local_end', $new_item); + Addon::callHooks('post_local', $item); + Addon::callHooks('post_remote', $item); + Addon::callHooks('post_local_end', $posted_item); + Addon::callHooks('post_remote_end', $posted_item); + Addon::callHooks('tagged', $arr); + Addon::callHooks('post_local_end', $new_item); ### src/Model/Contact.php - Addon::callHooks('contact_photo_menu', $args); - Addon::callHooks('follow', $arr); + Addon::callHooks('contact_photo_menu', $args); + Addon::callHooks('follow', $arr); ### src/Model/Profile.php - Addon::callHooks('profile_sidebar_enter', $profile); - Addon::callHooks('profile_sidebar', $arr); - Addon::callHooks('profile_tabs', $arr); - Addon::callHooks('zrl_init', $arr); + Addon::callHooks('profile_sidebar_enter', $profile); + Addon::callHooks('profile_sidebar', $arr); + Addon::callHooks('profile_tabs', $arr); + Addon::callHooks('zrl_init', $arr); ### src/Model/Event.php - - Addon::callHooks('event_updated', $event['id']); - Addon::callHooks("event_created", $event['id']); + + Addon::callHooks('event_updated', $event['id']); + Addon::callHooks("event_created", $event['id']); ### src/Model/User.php - - Addon::callHooks('register_account', $uid); - Addon::callHooks('remove_user', $user); + + Addon::callHooks('register_account', $uid); + Addon::callHooks('remove_user', $user); ### src/Content/Text/BBCode.php - - Addon::callHooks('bbcode', $text); - Addon::callHooks('bb2diaspora', $text); + + Addon::callHooks('bbcode', $text); + Addon::callHooks('bb2diaspora', $text); ### src/Content/Text/HTML.php - - Addon::callHooks('html2bbcode', $message); + + Addon::callHooks('html2bbcode', $message); ### src/Content/Smilies.php - - Addon::callHooks('smilie', $params); + + Addon::callHooks('smilie', $params); ### src/Content/Feature.php - - Addon::callHooks('isEnabled', $arr); - Addon::callHooks('get', $arr); + + Addon::callHooks('isEnabled', $arr); + Addon::callHooks('get', $arr); ### src/Content/ContactSelector.php - - Addon::callHooks('network_to_name', $nets); - Addon::callHooks('gender_selector', $select); - Addon::callHooks('sexpref_selector', $select); - Addon::callHooks('marital_selector', $select); -### src/Content/OEmbed.php + Addon::callHooks('network_to_name', $nets); + Addon::callHooks('gender_selector', $select); + Addon::callHooks('sexpref_selector', $select); + Addon::callHooks('marital_selector', $select); + +### src/Content/OEmbed.php Addon::callHooks('oembed_fetch_url', $embedurl, $j); -### src/Content/Nav.php +### src/Content/Nav.php Addon::callHooks('page_header', $a->page['nav']); Addon::callHooks('nav_info', $nav); ### src/Worker/Directory.php - - Addon::callHooks('globaldir_update', $arr); + + Addon::callHooks('globaldir_update', $arr); ### src/Worker/Notifier.php - - Addon::callHooks('notifier_end', $target_item); -### src/Worker/Queue.php + Addon::callHooks('notifier_end', $target_item); + +### src/Worker/Queue.php Addon::callHooks('queue_predeliver', $r); Addon::callHooks('queue_deliver', $params); ### src/Module/Login.php - Addon::callHooks('authenticate', $addon_auth); - Addon::callHooks('login_hook', $o); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('login_hook', $o); -### src/Module/Logout.php +### src/Module/Logout.php Addon::callHooks("logging_out"); ### src/Object/Post.php - - Addon::callHooks('render_location', $locate); - Addon::callHooks('display_item', $arr); + + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); ### src/Core/ACL.php - - Addon::callHooks('contact_select_options', $x); - Addon::callHooks($a->module.'_pre_'.$selname, $arr); - Addon::callHooks($a->module.'_post_'.$selname, $o); - Addon::callHooks($a->module.'_pre_'.$selname, $arr); - Addon::callHooks($a->module.'_post_'.$selname, $o); - Addon::callHooks('jot_networks', $jotnets); + + Addon::callHooks('contact_select_options', $x); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks('jot_networks', $jotnets); ### src/Core/Worker.php - - Addon::callHooks("proc_run", $arr); + + Addon::callHooks("proc_run", $arr); ### src/Util/Emailer.php - - Addon::callHooks('emailer_send_prepare', $params); - Addon::callHooks("emailer_send", $hookdata); + + Addon::callHooks('emailer_send_prepare', $params); + Addon::callHooks("emailer_send", $hookdata); ### src/Util/Map.php - - Addon::callHooks('generate_map', $arr); - Addon::callHooks('generate_named_map', $arr); - Addon::callHooks('Map::getCoordinates', $arr); + + Addon::callHooks('generate_map', $arr); + Addon::callHooks('generate_named_map', $arr); + Addon::callHooks('Map::getCoordinates', $arr); ### src/Util/Network.php - - Addon::callHooks('avatar_lookup', $avatar); + + Addon::callHooks('avatar_lookup', $avatar); ### src/Util/ParseUrl.php - - Addon::callHooks("getsiteinfo", $siteinfo); + + Addon::callHooks("getsiteinfo", $siteinfo); ### src/Protocol/DFRN.php - - Addon::callHooks('atom_feed_end', $atom); - Addon::callHooks('atom_feed_end', $atom); + + Addon::callHooks('atom_feed_end', $atom); + Addon::callHooks('atom_feed_end', $atom); diff --git a/doc/de/Addons.md b/doc/de/Addons.md index affc4ba2b..02be19e30 100644 --- a/doc/de/Addons.md +++ b/doc/de/Addons.md @@ -101,7 +101,7 @@ Derzeitige Hooks **'post_remote'** - wird aufgerufen, wenn ein Beitrag aus einer anderen Quelle empfangen wird. Dies kann auch genutzt werden, um lokale Aktivitäten oder systemgenerierte Nachrichten zu veröffentlichen/posten. $b ist das Item-Array einer Information, die in der Datenbank und im Item gespeichert ist. - {Bitte beachte: der Seiteninhalt ist bbcode - nicht HTML) + {Bitte beachte: der Seiteninhalt ist bbcode - nicht HTML) **'settings_form'** - wird aufgerufen, wenn die HTML-Ausgabe für die Einstellungsseite generiert wird. $b ist die HTML-Ausgabe (String) der Einstellungsseite vor dem finalen ""-Tag. @@ -206,12 +206,12 @@ Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Ap ### include/api.php - Addon::callHooks('logged_in', $a->user); - Addon::callHooks('authenticate', $addon_auth); - Addon::callHooks('logged_in', $a->user); + Addon::callHooks('logged_in', $a->user); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('logged_in', $a->user); ### include/enotify.php - + Addon::callHooks('enotify', $h); Addon::callHooks('enotify_store', $datarray); Addon::callHooks('enotify_mail', $datarray); @@ -227,8 +227,8 @@ Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Ap Addon::callHooks('jot_tool', $jotplugins); ### include/security.php - - Addon::callHooks('logged_in', $a->user); + + Addon::callHooks('logged_in', $a->user); ### include/text.php @@ -240,251 +240,251 @@ Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Ap Addon::callHooks('prepare_body_final', $hook_data); ### include/items.php - - Addon::callHooks('page_info_data', $data); + + Addon::callHooks('page_info_data', $data); ### mod/directory.php - - Addon::callHooks('directory_item', $arr); + + Addon::callHooks('directory_item', $arr); ### mod/xrd.php - - Addon::callHooks('personal_xrd', $arr); + + Addon::callHooks('personal_xrd', $arr); ### mod/ping.php - - Addon::callHooks('network_ping', $arr); + + Addon::callHooks('network_ping', $arr); ### mod/parse_url.php - - Addon::callHooks("parse_link", $arr); + + Addon::callHooks("parse_link", $arr); ### mod/manage.php - - Addon::callHooks('home_init', $ret); + + Addon::callHooks('home_init', $ret); ### mod/acl.php - - Addon::callHooks('acl_lookup_end', $results); + + Addon::callHooks('acl_lookup_end', $results); ### mod/network.php - - Addon::callHooks('network_content_init', $arr); - Addon::callHooks('network_tabs', $arr); + + Addon::callHooks('network_content_init', $arr); + Addon::callHooks('network_tabs', $arr); ### mod/friendica.php - - Addon::callHooks('about_hook', $o); - + + Addon::callHooks('about_hook', $o); + ### mod/subthread.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/profiles.php - - Addon::callHooks('profile_post', $_POST); - Addon::callHooks('profile_edit', $arr); + + Addon::callHooks('profile_post', $_POST); + Addon::callHooks('profile_edit', $arr); ### mod/settings.php - - Addon::callHooks('addon_settings_post', $_POST); - Addon::callHooks('connector_settings_post', $_POST); - Addon::callHooks('display_settings_post', $_POST); - Addon::callHooks('settings_post', $_POST); - Addon::callHooks('addon_settings', $settings_addons); - Addon::callHooks('connector_settings', $settings_connectors); - Addon::callHooks('display_settings', $o); - Addon::callHooks('settings_form', $o); + + Addon::callHooks('addon_settings_post', $_POST); + Addon::callHooks('connector_settings_post', $_POST); + Addon::callHooks('display_settings_post', $_POST); + Addon::callHooks('settings_post', $_POST); + Addon::callHooks('addon_settings', $settings_addons); + Addon::callHooks('connector_settings', $settings_connectors); + Addon::callHooks('display_settings', $o); + Addon::callHooks('settings_form', $o); ### mod/photos.php - - Addon::callHooks('photo_post_init', $_POST); - Addon::callHooks('photo_post_file', $ret); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', $foo); - Addon::callHooks('photo_post_end', intval($item_id)); - Addon::callHooks('photo_upload_form', $ret); + + Addon::callHooks('photo_post_init', $_POST); + Addon::callHooks('photo_post_file', $ret); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', $foo); + Addon::callHooks('photo_post_end', intval($item_id)); + Addon::callHooks('photo_upload_form', $ret); ### mod/profile.php - - Addon::callHooks('profile_advanced', $o); + + Addon::callHooks('profile_advanced', $o); ### mod/home.php - - Addon::callHooks('home_init', $ret); - Addon::callHooks("home_content", $content); + + Addon::callHooks('home_init', $ret); + Addon::callHooks("home_content", $content); ### mod/poke.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/contacts.php - - Addon::callHooks('contact_edit_post', $_POST); - Addon::callHooks('contact_edit', $arr); + + Addon::callHooks('contact_edit_post', $_POST); + Addon::callHooks('contact_edit', $arr); ### mod/tagger.php - - Addon::callHooks('post_local_end', $arr); + + Addon::callHooks('post_local_end', $arr); ### mod/lockview.php - - Addon::callHooks('lockview_content', $item); + + Addon::callHooks('lockview_content', $item); ### mod/uexport.php - - Addon::callHooks('uexport_options', $options); + + Addon::callHooks('uexport_options', $options); ### mod/register.php - - Addon::callHooks('register_post', $arr); - Addon::callHooks('register_form', $arr); + + Addon::callHooks('register_post', $arr); + Addon::callHooks('register_form', $arr); ### mod/item.php - - Addon::callHooks('post_local_start', $_REQUEST); - Addon::callHooks('post_local', $datarray); - Addon::callHooks('post_local_end', $datarray); -### mod/editpost.php + Addon::callHooks('post_local_start', $_REQUEST); + Addon::callHooks('post_local', $datarray); + Addon::callHooks('post_local_end', $datarray); + +### mod/editpost.php Addon::callHooks('jot_tool', $jotplugins); ### src/Network/FKOAuth1.php - - Addon::callHooks('logged_in', $a->user); + + Addon::callHooks('logged_in', $a->user); ### src/Render/FriendicaSmartyEngine.php - - Addon::callHooks("template_vars", $arr); + + Addon::callHooks("template_vars", $arr); ### src/Model/Item.php - Addon::callHooks('post_local', $item); - Addon::callHooks('post_remote', $item); - Addon::callHooks('post_local_end', $posted_item); - Addon::callHooks('post_remote_end', $posted_item); - Addon::callHooks('tagged', $arr); - Addon::callHooks('post_local_end', $new_item); + Addon::callHooks('post_local', $item); + Addon::callHooks('post_remote', $item); + Addon::callHooks('post_local_end', $posted_item); + Addon::callHooks('post_remote_end', $posted_item); + Addon::callHooks('tagged', $arr); + Addon::callHooks('post_local_end', $new_item); ### src/Model/Contact.php - Addon::callHooks('contact_photo_menu', $args); - Addon::callHooks('follow', $arr); + Addon::callHooks('contact_photo_menu', $args); + Addon::callHooks('follow', $arr); ### src/Model/Profile.php - Addon::callHooks('profile_sidebar_enter', $profile); - Addon::callHooks('profile_sidebar', $arr); - Addon::callHooks('profile_tabs', $arr); - Addon::callHooks('zrl_init', $arr); + Addon::callHooks('profile_sidebar_enter', $profile); + Addon::callHooks('profile_sidebar', $arr); + Addon::callHooks('profile_tabs', $arr); + Addon::callHooks('zrl_init', $arr); ### src/Model/Event.php - - Addon::callHooks('event_updated', $event['id']); - Addon::callHooks("event_created", $event['id']); + + Addon::callHooks('event_updated', $event['id']); + Addon::callHooks("event_created", $event['id']); ### src/Model/User.php - - Addon::callHooks('register_account', $uid); - Addon::callHooks('remove_user', $user); + + Addon::callHooks('register_account', $uid); + Addon::callHooks('remove_user', $user); ### src/Content/Text/BBCode.php - - Addon::callHooks('bbcode', $text); - Addon::callHooks('bb2diaspora', $text); + + Addon::callHooks('bbcode', $text); + Addon::callHooks('bb2diaspora', $text); ### src/Content/Text/HTML.php - - Addon::callHooks('html2bbcode', $message); + + Addon::callHooks('html2bbcode', $message); ### src/Content/Smilies.php - - Addon::callHooks('smilie', $params); + + Addon::callHooks('smilie', $params); ### src/Content/Feature.php - - Addon::callHooks('isEnabled', $arr); - Addon::callHooks('get', $arr); + + Addon::callHooks('isEnabled', $arr); + Addon::callHooks('get', $arr); ### src/Content/ContactSelector.php - - Addon::callHooks('network_to_name', $nets); - Addon::callHooks('gender_selector', $select); - Addon::callHooks('sexpref_selector', $select); - Addon::callHooks('marital_selector', $select); -### src/Content/OEmbed.php + Addon::callHooks('network_to_name', $nets); + Addon::callHooks('gender_selector', $select); + Addon::callHooks('sexpref_selector', $select); + Addon::callHooks('marital_selector', $select); + +### src/Content/OEmbed.php Addon::callHooks('oembed_fetch_url', $embedurl, $j); -### src/Content/Nav.php +### src/Content/Nav.php Addon::callHooks('page_header', $a->page['nav']); Addon::callHooks('nav_info', $nav); ### src/Worker/Directory.php - - Addon::callHooks('globaldir_update', $arr); + + Addon::callHooks('globaldir_update', $arr); ### src/Worker/Notifier.php - - Addon::callHooks('notifier_end', $target_item); -### src/Worker/Queue.php + Addon::callHooks('notifier_end', $target_item); + +### src/Worker/Queue.php Addon::callHooks('queue_predeliver', $r); Addon::callHooks('queue_deliver', $params); ### src/Module/Login.php - Addon::callHooks('authenticate', $addon_auth); - Addon::callHooks('login_hook', $o); + Addon::callHooks('authenticate', $addon_auth); + Addon::callHooks('login_hook', $o); -### src/Module/Logout.php +### src/Module/Logout.php Addon::callHooks("logging_out"); ### src/Object/Post.php - - Addon::callHooks('render_location', $locate); - Addon::callHooks('display_item', $arr); + + Addon::callHooks('render_location', $locate); + Addon::callHooks('display_item', $arr); ### src/Core/ACL.php - - Addon::callHooks('contact_select_options', $x); - Addon::callHooks($a->module.'_pre_'.$selname, $arr); - Addon::callHooks($a->module.'_post_'.$selname, $o); - Addon::callHooks($a->module.'_pre_'.$selname, $arr); - Addon::callHooks($a->module.'_post_'.$selname, $o); - Addon::callHooks('jot_networks', $jotnets); + + Addon::callHooks('contact_select_options', $x); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks($a->module.'_pre_'.$selname, $arr); + Addon::callHooks($a->module.'_post_'.$selname, $o); + Addon::callHooks('jot_networks', $jotnets); ### src/Core/Worker.php - - Addon::callHooks("proc_run", $arr); + + Addon::callHooks("proc_run", $arr); ### src/Util/Emailer.php - - Addon::callHooks('emailer_send_prepare', $params); - Addon::callHooks("emailer_send", $hookdata); + + Addon::callHooks('emailer_send_prepare', $params); + Addon::callHooks("emailer_send", $hookdata); ### src/Util/Map.php - - Addon::callHooks('generate_map', $arr); - Addon::callHooks('generate_named_map', $arr); - Addon::callHooks('Map::getCoordinates', $arr); + + Addon::callHooks('generate_map', $arr); + Addon::callHooks('generate_named_map', $arr); + Addon::callHooks('Map::getCoordinates', $arr); ### src/Util/Network.php - - Addon::callHooks('avatar_lookup', $avatar); + + Addon::callHooks('avatar_lookup', $avatar); ### src/Util/ParseUrl.php - - Addon::callHooks("getsiteinfo", $siteinfo); + + Addon::callHooks("getsiteinfo", $siteinfo); ### src/Protocol/DFRN.php - - Addon::callHooks('atom_feed_end', $atom); - Addon::callHooks('atom_feed_end', $atom); + + Addon::callHooks('atom_feed_end', $atom); + Addon::callHooks('atom_feed_end', $atom); From 66547e51075d429bb1cc05f6b6bcfac22bf0114c Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 25 Apr 2018 16:00:21 +0000 Subject: [PATCH 07/10] Don't distribute for ignored contacts --- src/Model/Item.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Item.php b/src/Model/Item.php index 8125c4ac7..c16281ae3 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -863,7 +863,7 @@ class Item extends BaseObject unset($item['id']); - $condition = ["`nurl` IN (SELECT `nurl` FROM `contact` WHERE `id` = ?) AND `uid` != 0 AND NOT `blocked` AND `rel` IN (?, ?)", + $condition = ["`nurl` IN (SELECT `nurl` FROM `contact` WHERE `id` = ?) AND `uid` != 0 AND NOT `blocked` AND NOT `readonly` AND `rel` IN (?, ?)", $parent['owner-id'], CONTACT_IS_SHARING, CONTACT_IS_FRIEND]; $contacts = dba::select('contact', ['uid'], $condition); while ($contact = dba::fetch($contacts)) { From f7f640175ab33d54ee231b625d31738382b04f20 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Thu, 26 Apr 2018 04:56:42 -0400 Subject: [PATCH 08/10] Fix PHP 7.2 warning in Model\Profile --- src/Model/Profile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Profile.php b/src/Model/Profile.php index f86fce9b2..d4773a806 100644 --- a/src/Model/Profile.php +++ b/src/Model/Profile.php @@ -950,7 +950,7 @@ class Profile ]; } - if ((!$is_owner) && ((count($a->profile)) || (!$a->profile['hide-friends']))) { + if (!$is_owner && empty($a->profile['hide-friends'])) { $tabs[] = [ 'label' => L10n::t('Contacts'), 'url' => System::baseUrl() . '/viewcontacts/' . $nickname, From da3658c80d7c9a2f681aece4372398e11679e7e4 Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 26 Apr 2018 19:47:12 +0000 Subject: [PATCH 09/10] =?UTF-8?q?Bugfix:=20The=20Distribition=20of=20publi?= =?UTF-8?q?c=20items=20failed=20with=20comments#=20Bitte=20geben=20Sie=20e?= =?UTF-8?q?ine=20Commit-Beschreibung=20f=C3=BCr=20Ihre=20=C3=84nderungen?= =?UTF-8?q?=20ein.=20Zeilen,?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Model/Item.php | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/Model/Item.php b/src/Model/Item.php index c16281ae3..14d2f8009 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -863,11 +863,24 @@ class Item extends BaseObject unset($item['id']); + $users = []; + $condition = ["`nurl` IN (SELECT `nurl` FROM `contact` WHERE `id` = ?) AND `uid` != 0 AND NOT `blocked` AND NOT `readonly` AND `rel` IN (?, ?)", $parent['owner-id'], CONTACT_IS_SHARING, CONTACT_IS_FRIEND]; $contacts = dba::select('contact', ['uid'], $condition); while ($contact = dba::fetch($contacts)) { - self::storeForUser($itemid, $item, $contact['uid']); + $users[$contact['uid']] = $contact['uid']; + } + + if ($item['uri'] != $item['parent-uri']) { + $parents = dba::select('item', ['uid'], ["`uri` = ? AND `uid` != 0", $item['parent-uri']]); + while ($parent = dba::fetch($parents)) { + $users[$parent['uid']] = $parent['uid']; + } + } + + foreach ($users as $uid) { + self::storeForUser($itemid, $item, $uid); } } From 4a792761d1ddc153a9cfff717fee98339dbedb4b Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 26 Apr 2018 20:11:29 +0000 Subject: [PATCH 10/10] Item distribution: Better don't store these values --- src/Model/Item.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Model/Item.php b/src/Model/Item.php index 14d2f8009..aa3800cbe 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -862,6 +862,14 @@ class Item extends BaseObject } unset($item['id']); + unset($item['parent']); + unset($item['mention']); + unset($item['wall']); + unset($item['origin']); + unset($item['global']); + unset($item['starred']); + unset($item['rendered-hash']); + unset($item['rendered-html']); $users = [];