Compare commits

...

173 commits

Author SHA1 Message Date
Hypolite Petovan cfff03f6e2 [v2.4.2] Bump version number for release 2024-03-07 14:18:49 -05:00
Tobias Diekershoff 4524ad166b Merge pull request 'Move Visit server link to server name' (#103) from MrPetovan/friendica-directory:enhancement/100-move-visit-server-link into stable
Reviewed-on: #103
2024-03-07 15:48:26 +01:00
Hypolite Petovan 2ffb047736 Move Visit server link to server name 2024-03-07 09:42:45 -05:00
heluecht f4bff37432 Merge pull request 'Update source code link to point to Friendica's Forgejo' (#101) from MrPetovan/friendica-directory:enhancement/97-source-code-link into stable
Reviewed-on: #101
2024-03-07 15:36:49 +01:00
heluecht 62c6c0f1cc Merge pull request 'Change icon for Approval registration policy from dungeon door to stamp' (#102) from MrPetovan/friendica-directory:enhancement/99-unstable-version-icon into stable
Reviewed-on: #102
2024-03-07 15:35:43 +01:00
Hypolite Petovan 5f79768a6b Change icon for unstable version from poop to bug 2024-03-07 09:23:51 -05:00
Hypolite Petovan 08950be588 Change icon for Approval registration policy from dungeon door to stamp 2024-03-07 09:23:36 -05:00
Hypolite Petovan 9d77067e79 Update source code link to point to Friendica's Forgejo 2024-03-07 09:21:03 -05:00
Tobias Diekershoff 13b95e22da Merge pull request '[Composer] Change gofabian/negotiation-middleware dependency requirement to support PHP 8.2' (#96) from MrPetovan/friendica-directory:bug/php-8 into stable
Reviewed-on: #96
2023-08-09 07:01:21 +02:00
Hypolite Petovan 9d296b9f5d [Composer] Change gofabian/negotiation-middleware dependency requirement to support PHP 8
- Add now-explicit laminas/laminas-zendframework-bridge dependency
- Bump PHP version requirement to 7.3.0
- Updating willdurand/negotiation (v2.3.1 => 3.1.0) (PHP 8 compatibility)
- Updating psr/http-message (1.0.1 => 1.1)
- Removing gofabian/negotiation-middleware (v0.1.3)
- Installing gofabian/negotiation-middleware (dev-master 4d3cda5)
- Updating gettext/languages (2.9.0 => 2.10.0)
- Updating gettext/gettext (v4.8.6 => v4.8.8)
- Updating guzzlehttp/psr7 (1.8.5 => 1.9.1)
- Updating guzzlehttp/promises (1.5.1 => 1.5.3)
- Updating symfony/polyfill-php72 (v1.26.0 => v1.27.0)
- Updating symfony/polyfill-intl-normalizer (v1.26.0 => v1.27.0)
- Updating symfony/polyfill-intl-idn (v1.26.0 => v1.27.0)
- Updating guzzlehttp/guzzle (6.5.6 => 6.5.8)
- Updating laminas/laminas-escaper (2.6.1 => 2.9.0)
- Updating laminas/laminas-zendframework-bridge (1.1.1 => 1.4.1)
- Updating masterminds/html5 (2.7.5 => 2.8.0)
- Updating monolog/monolog (1.26.1 => 1.27.1)
- Updating psr/container (1.0.0 => 1.1.1)
- Updating pimple/pimple (v3.2.3 => v3.5.0)
- Updating slim/slim (3.12.3 => 3.12.5)
- Updating pear/pear-core-minimal (v1.10.11 => v1.10.13)
2023-07-31 01:24:50 +02:00
Hypolite Petovan bf85c8f986 Catch rare exception receiving line folding characters in header value of redirected request 2023-07-31 01:17:33 +02:00
Hypolite Petovan 064fd922e7 Add default profile picture path dependency
- Update default profile picture
2023-07-31 01:11:33 +02:00
Hypolite Petovan 95ffadb19f Fix ternary operator ambiguity deprecation in Utils\L10n 2023-07-31 01:10:37 +02:00
Tobias Diekershoff 8bd1cb11ae Merge pull request 'Rename "forum" to "group"' (#94) from MrPetovan/friendica-directory:task/rename-forum-to-group into stable
Reviewed-on: #94
2023-06-05 06:37:27 +02:00
Hypolite Petovan aade2ec534 Rename "forum" to "group"
- This reflects a change in Friendica Core
2023-06-04 00:16:38 -04:00
Hypolite Petovan f854d7d5f7 Fix several PHP messages
- Add logging for exceptions
2023-03-12 17:49:44 -04:00
Tobias Diekershoff 230f17ef36 Merge pull request 'Normalize HTTP client user agent' (#90) from MrPetovan/friendica-directory:task/89-normalize-user-agent into stable
Reviewed-on: #90
2022-06-07 05:40:29 +00:00
Hypolite Petovan 30f6e6f5de [Composer] Remove unused dependency byjg/webrequest 2022-06-06 02:23:57 -04:00
Hypolite Petovan d1a72232b3 Replace ByJG\WebRequest by GuzzleHttp\ClientInterface 2022-06-06 02:22:56 -04:00
Hypolite Petovan 9ff681a460 Fix database error with false bolean value in profile table 2022-06-06 02:22:39 -04:00
Hypolite Petovan 0ee5bf55b1 Replace direct curl uses with Guzzle HTTP client
- Add http dependency with custom User Agent
- Simplify profile poll to remove the second profile call to check availability
- Remove obsolete Network::fetchURL and Network::testURL
2022-06-06 02:22:37 -04:00
Hypolite Petovan 5829108c0e [Composer] Require guzzlehttp/guzzle:^6.5 2022-06-06 01:32:00 -04:00
Hypolite Petovan 91aa66ed77 [v2.4.1] Bump version number for release 2022-05-12 14:18:43 -04:00
Hypolite Petovan 7fdbaa3678 Don't encode the zrl parameter in external links
- Fix a "Forbidden" issue with /remote_follow links
2022-05-12 14:18:19 -04:00
Hypolite Petovan df660b66c9 [v2.4.0] Bump version number for release 2022-05-12 09:15:19 -04:00
heluecht 3f38b3adea Merge pull request 'Remove obsolete profile.dfrn_request field' (#87) from MrPetovan/friendica-directory:task/86-remove-dfrn_request into stable
Reviewed-on: #87
2022-05-11 04:17:41 +00:00
Hypolite Petovan e65bb660ce [Database v0010] Drop unused column profile.dfrn_request 2022-05-07 16:10:43 -04:00
Hypolite Petovan a5700cb2c9 Remove references to dfrn_request 2022-05-07 16:10:43 -04:00
Hypolite Petovan 2627b54349 Replace dfrn_request by subscribe URL when available for the follow link
- Falls back to the `/remote_follow` module available since Friendica version 2020.03
- Falls back to the profile URL
- Remove unused atlas dependency in a couple API controllers
2022-05-07 16:10:42 -04:00
Hypolite Petovan 8988ad9f9d Add subscribe URL retrieval to server poll 2022-05-07 16:09:30 -04:00
Hypolite Petovan 7d5012e72e [Database v0009] Add server.subscribe_url field 2022-05-07 16:09:30 -04:00
Hypolite Petovan b0142f6ab2 Add optional version parameter to console updatedb 2022-05-07 16:09:29 -04:00
Hypolite Petovan cd809f7646 Remove mention of non-existent console parameters in Install and UpdateDb 2022-05-07 16:09:29 -04:00
Hypolite Petovan 2aba91d42c Add HTML link to profile to account name
- Normalize white space in HTML
2022-05-07 16:09:27 -04:00
Hypolite Petovan 2e84f5aa7b Merge pull request 'added DA DK translation THX atjn' (#88) from tobias/friendica-directory:20220501-daDK into stable
Reviewed-on: #88
2022-05-04 21:45:51 +00:00
Tobias Diekershoff 1ebddb042f
PL translation updated THX strebski 2022-05-03 09:17:55 +02:00
Tobias Diekershoff 0344c77336
added DA DK translation THX atjn 2022-05-01 20:17:13 +02:00
Hypolite Petovan 5a16bcb57c Merge pull request 'PL translation updated THX strebski' (#85) from tobias/friendica-directory:20220318-pl into stable
Reviewed-on: #85
2022-04-25 11:27:41 +00:00
Tobias Diekershoff 146d4e6374
PL translation updated THX strebski 2022-03-18 17:41:59 +01:00
Hypolite Petovan ef91f43be0 [v2.3.5] Bump version number for release 2022-01-23 06:13:16 -05:00
Hypolite Petovan a3a5bd8ab4 Merge pull request 'added SV translation THX Kristoffer Grundström' (#84) from tobias/friendica-directory:20220122-sv into stable
Reviewed-on: #84
2022-01-23 01:27:15 +00:00
Tobias Diekershoff c34fcd11f8 added Swedish to the languages array 2022-01-22 19:09:24 +01:00
Tobias Diekershoff 1356001334 added SV translation THX Kristoffer Grundström 2022-01-22 19:08:37 +01:00
Hypolite Petovan b344935edc [v2.3.4] Bump version number for release 2022-01-10 02:24:09 -05:00
Hypolite Petovan 5de396bc67 Add Hungarian to the available languages 2022-01-09 18:16:15 -05:00
Hypolite Petovan fe9b12164d [v2.3.3] Bump version number for release 2021-12-29 18:57:18 +01:00
Hypolite Petovan 6ccbeef59c [Composer] Updated dependencies before release
- Updating atlas/pdo (1.1.2 => 1.2.0)
  - Updating gettext/languages (2.6.0 => 2.9.0)
  - Updating gettext/gettext (v4.8.2 => v4.8.6)
  - Updating masterminds/html5 (2.7.1 => 2.7.5)
  - Updating psr/log (1.1.3 => 1.1.4)
  - Updating monolog/monolog (1.25.4 => 1.26.1)
  - Updating sarahman/simple-filesystem-cache (1.0.1 => 1.0.2)
  - Updating seld/cli-prompt (1.0.3 => 1.0.4)
  - Updating bower-asset/fontawesome (5.13.1 => 5.15.4)
  - Updating laminas/laminas-zendframework-bridge (1.0.4 => 1.1.1)
  - Updating pear/pear_exception (v1.0.1 => v1.0.2)
  - Updating pear/pear-core-minimal (v1.10.10 => v1.10.11)
2021-12-29 17:24:24 +01:00
Hypolite Petovan 4e3dcaf331 Merge pull request 'added HU translation' (#82) from tobias/friendica-directory:20211206-hu into stable
Reviewed-on: #82
2021-12-06 19:41:57 +00:00
Tobias Diekershoff ca605b8f23 added HU translation
fixes #73
2021-12-06 20:29:32 +01:00
Hypolite Petovan 13733e2f6c Merge pull request 'AR translation update THX abidin toumi' (#81) from tobias/friendica-directory:20211030-ar into stable
Reviewed-on: #81
2021-10-30 12:37:07 +00:00
Tobias Diekershoff d22b656a46 AR translation update THX abidin toumi 2021-10-30 08:27:49 +02:00
Tobias Diekershoff b3a8ea85f1 Merge pull request '[Composer] Update mrpetovan/net_ping to version 1.2.1' (#80) from MrPetovan/friendica-directory:task/79-composer-dependencies into stable
Reviewed-on: #80
2021-09-16 05:15:07 +00:00
Hypolite Petovan 2a747cbb06 [Composer] Update mrpetovan/net_ping to version 1.2.1
- Suppresses a couple of Deprecation Notices when running Composer
2021-09-15 21:56:00 -04:00
Hypolite Petovan ffea0fcbdb Add Composer 1.* binary to project
- It is required to keep the fxp/composer-asset-plugin support
2021-09-15 21:16:38 -04:00
Hypolite Petovan 1507bfdcf8
Merge pull request #78 from tobiasd/20210715-gd
add translation for Gaelic, Scottish
2021-07-15 15:40:26 -04:00
Tobias Diekershoff b8332ac785 added Gaelic, Scottish to the language array 2021-07-15 15:10:57 +02:00
Tobias Diekershoff f707df488b added Gaelic, Scottish translation THX GunChleoc 2021-07-15 15:05:44 +02:00
Michael Vogel 750e369f57
Merge pull request #77 from MrPetovan/bug/76-remove-at-sign-fulltext-search
Remove at sign (@) from fulltext query string
2021-06-22 16:05:21 +02:00
Hypolite Petovan 4d7067b381 Remove at sign (@) from fulltext query string
- InnoDB uses it as a special character and it can't be escaped
2021-06-21 11:15:57 -04:00
Hypolite Petovan 7112c65166
Merge pull request #71 from Quix0r/fixes/timeout-class-reference
Fixes:
2020-10-25 22:52:29 -04:00
Roland Häder 193b01cccd
Used \Some\Foo::class instead of '\Some\Foo' which type-safe and easier to find by your editor/IDE
Signed-off-by: Roland Häder <roland@mxchange.org>
2020-10-26 01:19:41 +01:00
Tobias Diekershoff 9b4961e2cc
Merge pull request #68 from MrPetovan/task/3-add-server-language-filter
Add language filter to server list
2020-09-27 21:45:41 +02:00
Hypolite Petovan cb0bfae1ab [Composer] Add expected ext-pdo dependency 2020-09-27 15:39:09 -04:00
Hypolite Petovan 16d1962324 Add language filter to server list 2020-09-27 15:39:09 -04:00
Hypolite Petovan e68b68110b Create new popular server languages widget
- Rename popular profile widget class and template
2020-09-27 15:39:08 -04:00
Tobias Diekershoff a1921c999d
Merge pull request #67 from MrPetovan/task/31-add-limit-to-search
Add page size parameter to search
2020-09-27 20:05:17 +02:00
Hypolite Petovan 959f526cb4 Add page size parameter to search
- Update API call documentation
2020-09-27 13:41:40 -04:00
Tobias Diekershoff 72d5e68c96
Merge pull request #66 from MrPetovan/task/34-no-desc-health-cap
Cap health score if server doesn't have a description
2020-09-27 19:16:49 +02:00
Hypolite Petovan aa83091458 Cap health if server doesn't have a description 2020-09-27 12:51:34 -04:00
Michael Vogel 4205323d31
Merge pull request #65 from MrPetovan/task/36-display-registration-policy
Display registration policy in server panel
2020-09-27 18:03:12 +02:00
Hypolite Petovan 7b906d5e33 Updated base translation file after adding new translation strings 2020-09-27 11:58:07 -04:00
Hypolite Petovan 35194f8110 Display registration policy in server panel
- Add title to health score badge
- Add translation for users badge
2020-09-27 11:58:06 -04:00
Tobias Diekershoff 520ddf5a8c
Merge pull request #63 from MrPetovan/task/54-no-ping-penalty
Factor in the unavailability of ping in the health score
2020-09-27 17:56:49 +02:00
Tobias Diekershoff a24a7d866c
Merge pull request #64 from MrPetovan/task/40-add-account-types
Add additional account types to the profile filter
2020-09-27 17:43:18 +02:00
Hypolite Petovan f1b960c4eb Add additional account types to the profile filter 2020-09-27 11:31:18 -04:00
Hypolite Petovan 0ce9dda5f6 Factor in the unavailability of ping in the health score
- No available ping limits the maximum health score a server can have
2020-09-27 11:08:39 -04:00
Tobias Diekershoff 360c421796
Merge pull request #62 from MrPetovan/task/39-search-match-username
Add missing column in profile fulltext index
2020-09-27 14:46:56 +02:00
Hypolite Petovan b7eab197b5 Update API profile search request to match updated fulltext index definition 2020-09-27 08:39:31 -04:00
Hypolite Petovan 3939800068 [Database v0008b] Add missing column in fulltext index
- Add minimal SQL query to downgrade SQL script to avoid empty query errors
2020-09-27 08:39:18 -04:00
Michael Vogel 96dec7c4df
Merge pull request #60 from MrPetovan/task/39-search-match-username
Profile search now matches username, not full profile URL
2020-09-27 00:47:15 +02:00
Hypolite Petovan d6bf75ae04 Update profile search request to match updated fulltext index definition 2020-09-26 18:32:43 -04:00
Hypolite Petovan 4621ae2001 [Database v0008] Replace profile_url with username in profile full-text index
- Prevents search matches on node domain name
2020-09-26 18:32:21 -04:00
Michael Vogel 7780d3af09
Merge pull request #59 from MrPetovan/bug/38-unique-server-alias
Add unique key on server_alias.alias
2020-09-27 00:28:19 +02:00
Hypolite Petovan e873d62e2c Expand ON DUPLICATE KEY statement to match the new unique key 2020-09-26 18:09:21 -04:00
Hypolite Petovan 8e6aa14704 [Database v0007] Add unique key on server_alias.alias
- Fix inconsistent behaviors with aliases referring to multiple servers
2020-09-26 18:09:08 -04:00
Michael Vogel 751a45fd3c
Merge pull request #58 from MrPetovan/bug/47-drop-server-path-field
[Database v0006] Drop unused server.path field
2020-09-26 23:11:16 +02:00
Michael Vogel b48c436141
Merge pull request #57 from MrPetovan/bug/45-drop-key-validation
Remove validity check on profile key parameter
2020-09-26 23:07:49 +02:00
Hypolite Petovan ca0bb09f81 [Database v0006] Drop unused server.path field
- Fix "Field 'path' doesn't have a default value" errors
2020-09-26 17:06:40 -04:00
Hypolite Petovan c21642d705 Improve logging for invalid parameters during profile polling 2020-09-26 16:33:55 -04:00
Hypolite Petovan c8fa6ef3dc Remove validity check on profile key parameter 2020-09-26 16:33:29 -04:00
Hypolite Petovan ffa16d1935
Merge pull request #55 from realkinetix/server-max-health-fix
Fix $server_max_health value being overwritten while calculating
2020-09-13 22:26:42 -04:00
Adam Clark 69b2356a1b Fix $server_max_health value being overwritten while calculating 2020-09-13 23:12:48 +00:00
Michael Vogel 1ca13876fb
Merge pull request #52 from tobiasd/20200901-it
IT translation update THX Sylke Vicious
2020-09-01 15:11:23 +02:00
Tobias Diekershoff fad8939cb4 IT translation update THX Sylke Vicious 2020-09-01 15:02:27 +02:00
Hypolite Petovan 896a07f9cb
Merge pull request #51 from tobiasd/20200818-lng
EN GB and PL translation updates
2020-08-18 11:54:12 -04:00
Tobias Diekershoff 1451b18460 PL translation updated THX Waldis 2020-08-18 17:51:53 +02:00
Tobias Diekershoff d04b50d2b9 EN GB translation updated THX AndyH3 2020-08-18 17:51:27 +02:00
Hypolite Petovan c41ce95f4e
Merge pull request #50 from annando/user-agent
User agent added
2020-07-17 19:47:34 -04:00
Michael 776851b84f User agent added 2020-07-17 20:41:02 +00:00
Michael Vogel 937fedc2c7
Merge pull request #46 from MrPetovan/release/2.3.1
Release 2.3.1
2020-06-20 22:54:07 +02:00
Hypolite Petovan 0c203131b9 Increase specificity of checks of $param
- Avoids warnings and notices
2020-06-20 12:47:17 -04:00
Hypolite Petovan 7799fb99ed [Composer] Update dependency mrpetovan/Net_Ping to version 1.2 2020-06-20 12:45:18 -04:00
Hypolite Petovan b6933785dd [Composer] Update lock file hash 2020-06-17 15:16:39 -04:00
Tobias Diekershoff 83aa5152aa
Merge pull request #44 from MrPetovan/release/2.3.0
Release 2.3.0
2020-06-17 19:50:29 +02:00
Hypolite Petovan 9ee72bb382 Update container namespace after dependency replacement
- container-interop has been replaced with psr/container
2020-06-17 09:27:20 -04:00
Hypolite Petovan ad6db150c5 Update references to friendica/friendica-directory stable branch 2020-06-15 14:05:26 -04:00
Hypolite Petovan 30bdf306ba Bump version number for 2.3.0 release 2020-06-15 14:05:26 -04:00
Hypolite Petovan 5c9432dd57 [Composer] Replace abandoned leafo/scssphp with scssphp/scssphp 2020-06-15 14:05:21 -04:00
Hypolite Petovan 19631ef206 [Composer] Update dependencies
- Removing sebastian/resource-operations (1.0.0)
  - Removing sebastian/code-unit-reverse-lookup (1.0.1)
  - Removing myclabs/deep-copy (1.8.1)
  - Removing container-interop/container-interop (1.2.0)
  - Removing sebastian/object-enumerator (2.0.1)
  - Updating fxp/composer-asset-plugin (v1.4.4 => v1.4.6)
  - Updating atlas/pdo (1.1.1 => 1.1.2)
  - Updating boronczyk/localization-middleware (1.4 => 1.4.1)
  - Updating byjg/anydataset (4.0.0 => 4.0.1)
  - Updating byjg/anydataset-db (4.0.0 => 4.0.1)
  - Updating byjg/migration (4.0.2 => 4.0.3)
  - Updating gettext/languages (2.5.0 => 2.6.0)
  - Updating gettext/gettext (v4.6.2 => v4.8.2)
  - Updating masterminds/html5 (2.5.0 => 2.7.1)
  - Updating psr/log (1.1.0 => 1.1.3)
  - Updating monolog/monolog (1.24.0 => 1.25.4)
  - Downgrading sebastian/version (2.0.1 => 1.0.6)
  - Downgrading sebastian/recursion-context (2.0.0 => 1.0.5)
  - Downgrading sebastian/exporter (2.0.0 => 1.2.2)
  - Downgrading sebastian/environment (2.0.0 => 1.3.8)
  - Updating symfony/polyfill-ctype (v1.10.0 => v1.17.0)
  - Updating webmozart/assert (1.4.0 => 1.5.0)
  - Updating phpdocumentor/reflection-common (1.0.1 => 2.1.0)
  - Updating phpdocumentor/type-resolver (0.4.0 => 1.0.1)
  - Updating phpdocumentor/reflection-docblock (4.3.0 => 4.3.4)
  - Updating doctrine/instantiator (1.1.0 => 1.3.1)
  - Updating phpspec/prophecy (1.8.0 => v1.10.3)
  - Downgrading phpunit/phpunit-mock-objects (3.4.4 => 2.3.8)
  - Downgrading phpunit/php-token-stream (2.0.2 => 1.4.12)
  - Downgrading phpunit/php-code-coverage (4.0.8 => 2.2.4)
  - Downgrading phpunit/phpunit (5.7.27 => 4.8.36)
  - Updating sarahman/simple-filesystem-cache (1.0.0 => 1.0.1)
  - Updating slim/slim (3.12.0 => 3.12.3)
  - Updating slim/php-view (2.2.0 => 2.2.1)
  - Updating bower-asset/bootstrap.native (2.0.25 => 2.0.27)
  - Updating bower-asset/fontawesome (5.7.2 => 5.13.0)
  - Updating bower-asset/bootstrap (v4.3.1 => v4.5.0)
  - Updating leafo/scssphp (v0.7.7 => v0.7.8)
  - Updating pear/pear_exception (v1.0.0 => v1.0.1)
  - Updating composer/xdebug-handler (1.3.2 => 1.4.2)
  - Updating netresearch/jsonmapper (v1.4.0 => v1.6.0)
  - Updating felixfbecker/advanced-json-rpc (v3.0.3 => v3.1.1)
  - Updating felixfbecker/language-server-protocol (v1.2.0 => v1.4.0)
  - Updating nikic/php-parser (v4.2.1 => v4.5.0)
  - Updating sabre/event (5.0.3 => 5.1.0)
  - Updating sabre/uri (2.1.1 => 2.2.0)
2020-06-15 09:43:08 -04:00
Hypolite Petovan 685772e24e [Composer] Replace abandoned zendframefork/zend-escape with suggested laminas/laminas-escape 2020-06-15 09:43:07 -04:00
Hypolite Petovan deabe4da49 [Composer] Enforce minimum PHP version during composer update
- Downgrade symfony/yaml to version v3.4.42 to satisfy the enforced minimum PHP version
2020-06-15 09:43:07 -04:00
Michael Vogel d509dfbbfd
Merge pull request #43 from tobiasd/master
updated CS, DE, FR and added ar  ca  cs  de  en  en_GB  et  fr  it  ja  nl  pl  ru  th  zh_CN translation
2020-06-15 10:38:29 +02:00
Tobias Diekershoff aeb0a67b12 updated CS, DE, FR and added ar ca cs de en en_GB et fr it ja nl pl ru th zh_CN translation 2020-06-15 09:54:58 +02:00
Michael Vogel 2eca458ec1
Merge pull request #42 from MrPetovan/master
Use byjg/uri dependency instead of adding new URL-handling library
2020-06-14 21:31:21 +02:00
Hypolite Petovan b0a258cd0e Use byjg/uri dependency instead of adding new URL-handling library in PHPRenderer 2020-06-14 15:13:18 -04:00
Hypolite Petovan e082c0535d [Composer] Added core dependency byjg/uri 2020-06-14 15:13:17 -04:00
Michael Vogel b030cfd4e3
Merge pull request #41 from friendica/task/24-add-zrl-parameter-support
Add zrl parameter support
2020-06-14 09:37:05 +02:00
Hypolite Petovan 6cdbcbddb1 [translation] Update translation files after string update 2020-06-13 13:25:05 -04:00
Hypolite Petovan 476f7ae832 Add ZRL parameter support sitewide in templates 2020-06-13 13:21:18 -04:00
Hypolite Petovan 57dd610e73 Add u() and r() method to PhpRenderer
- Add Router dependency
2020-06-13 13:20:49 -04:00
Hypolite Petovan 0cdbd3af2d Add ZrlMiddleware to the stack 2020-06-13 13:17:40 -04:00
Hypolite Petovan 230ceeab29 Add names to routes we need to get URLs for 2020-06-13 13:17:19 -04:00
Hypolite Petovan f47f263fc3 Add ZrlMiddleware class 2020-06-13 13:16:35 -04:00
Hypolite Petovan a402fbdf5d Add Utils\Url class 2020-06-13 13:16:25 -04:00
Hypolite Petovan 10edbea99e Update author email address in file headers 2020-06-13 13:15:53 -04:00
Hypolite Petovan c18551c44c
Merge pull request #35 from AlfredSK/AlfredSK-change-queries-from-open-to-not-closed
Show and count also servers with policy 'approve'
2019-11-01 13:05:27 -04:00
Steffen K9 dfd1a14300
Change the statistics query as well 2019-11-01 17:18:15 +01:00
Steffen K9 778168e0c4
Show also servers with policy 'approve'
Changed the queries to show also servers with register policy 'approval'.
2019-11-01 17:15:26 +01:00
Hypolite Petovan 1e3dab7c10
Merge pull request #32 from tobiasd/20190930-lng
Updated translations of directory from Transifex sources
2019-10-01 07:58:30 -04:00
Tobias Diekershoff 8c602d3566 updated CS, DE, FR and added AR, en_GB, ET, IT, JA, NL, PL, TH, zh_CN translation 2019-09-30 20:38:28 +02:00
Tobias Diekershoff 2e1812a369 added language codes to the settings.php file 2019-09-30 20:35:41 +02:00
Hypolite Petovan a0cfd33521 Fix queries to work with sql_mode=only_full_group_by 2019-05-12 14:00:44 -04:00
Hypolite Petovan 942de39e6d Release 2.2.1 2019-03-04 22:21:00 -05:00
Hypolite Petovan 6ada08b8f7 [Composer] Update dependencies
- Update atlas/pdo (1.1.0 => 1.1.1)
- Update bower-asset/fontawesome (5.7.1 => 5.7.2)
2019-03-04 22:21:00 -05:00
Hypolite Petovan a7a9001f5e [Database v0005] Change server.ssl_state column type to tinyint
- Fix "Data truncated" SQL error with server.ssl_state column type
2019-03-04 22:11:38 -05:00
Hypolite Petovan c0ff5c1cba [Composer] Use stable release for sarahman/simple-filesystem-cache 2019-03-04 22:07:27 -05:00
Hypolite Petovan 2324c4836f Remove unused use statement in Controllers\Console\ExtractStrings 2019-03-04 22:05:23 -05:00
Hypolite Petovan 45fc6315b3 Release 2.2.0 2019-02-03 09:54:31 -05:00
Hypolite Petovan eb8ea589bc [Composer] Updating dependencies
- Updating gettext/gettext (v4.6.1 => v4.6.2)
- Updating masterminds/html5 (2.4.0 => 2.5.0)
- Updating slim/slim (3.11.0 => 3.12.0)
- Updating bower-asset/bootstrap.native (2.0.24 => 2.0.25)
- Updating bower-asset/fontawesome (5.6.1 => 5.7.1)
- Updating bower-asset/bootstrap (v4.1.3 => v4.2.1)
- Updating symfony/yaml (v4.2.1 => v4.2.3)
- Updating composer/xdebug-handler (1.3.1 => 1.3.2)
- Updating nikic/php-parser (v4.1.0 => v4.2.0)
- Updating webmozart/assert (1.3.0 => 1.4.0)
2019-02-03 09:54:23 -05:00
Hypolite Petovan 1bbe4d3289 Add SSL and availability condition in /servers/surprise (#15) 2019-02-03 09:36:53 -05:00
Hypolite Petovan d0102327c0 Add /servers/surprise endpoint 2019-02-03 09:30:31 -05:00
Hypolite Petovan 0e4d5a035f Fix search parameter handling (#23)
- Add default value for search parameter
- Fix filter_var flags for language parameter
2019-02-03 09:20:58 -05:00
Hypolite Petovan b6aaa246f6
Merge pull request #22 from Aditoo17/master
L10n: Update Czech translation
2019-01-27 04:50:15 -05:00
Aditoo17 d45651328e L10n: Update Czech translation 2019-01-27 08:53:00 +01:00
Hypolite Petovan 4da3acb52a Align /msearch output to legacy format 2018-12-24 09:45:47 -05:00
Hypolite Petovan 2fcd282e83 Add documentation for /msearch endpoint 2018-12-23 21:23:08 -05:00
Hypolite Petovan 8db05cfa7c Add new POST route /msearch with associated controller 2018-12-23 21:22:52 -05:00
Hypolite Petovan dc67cff8ef [Database v0004] Add fulltext index to profile for interest match 2018-12-23 21:18:09 -05:00
Hypolite Petovan fc447f07c4 Clean code of Api\Search 2018-12-23 21:15:50 -05:00
Hypolite Petovan 31feea1b7a Updated font awesome paths for version 5.6 2018-12-19 05:52:50 -05:00
Hypolite Petovan 8ca7dfb455 Release 2.1.1 2018-12-19 05:40:48 -05:00
Hypolite Petovan d33fb62e35 Add support for RC version (#19) 2018-12-19 04:09:23 -05:00
Hypolite Petovan 503c134df6 [Composer] Updated font-awesome to version 5.6.1 2018-12-19 03:59:45 -05:00
Hypolite Petovan 6c01f2d3e5 [Composer] Update byjg/migration to version 4.0.2 2018-12-19 03:55:30 -05:00
Hypolite Petovan b561a1a49d Updated README about custom pages 2018-11-19 22:47:39 -05:00
Hypolite Petovan b61afa9502 Add support for multi-word custom HTML page name 2018-11-19 22:43:34 -05:00
Hypolite Petovan 6d4354c97f Update composer.lock 2018-11-19 22:42:17 -05:00
Hypolite Petovan 80e9283c41 Release 2.1.0 2018-11-19 22:32:47 -05:00
Hypolite Petovan c2de5cf80a Add de_DE to available locales 2018-11-19 22:32:20 -05:00
Hypolite Petovan aa25c475dc Update translations before release
- Add partial de translations
- Update fr translations
2018-11-19 22:20:56 -05:00
Hypolite Petovan e30065657d Fix missing argument in servers controller 2018-11-19 22:13:47 -05:00
Hypolite Petovan e36805c206 Add Custom Pages feature
- Add config/pages directory
- Add new custom pages controller and route
- Add generated links in the footer
2018-11-19 22:12:09 -05:00
Hypolite Petovan 8c1d4404c7 Add new expected abstract method to Web\BaseController
- Cleanup obsolete use statements
2018-11-19 22:11:22 -05:00
Hypolite Petovan 9f80a14565 Add footer with current version
- Move stats links from header to footer
2018-11-19 08:32:58 -05:00
Hypolite Petovan c0a56882bc Fix FR translation 2018-11-18 11:46:22 -05:00
Hypolite Petovan 2505436796 Add missing translation string in Layout 2018-11-18 11:40:05 -05:00
Hypolite Petovan d2a9099391 Update translation strings
- Update FR translations
2018-11-18 11:35:42 -05:00
Hypolite Petovan 2591f05fb5 Add translation strings to statistics page 2018-11-18 11:35:23 -05:00
Hypolite Petovan 0c3013adeb Add locale support to extract-strings console
- Remove reliance on available locales setting
- Add reliance on translation path setting
- Only create a new translation when a single language is provided
- Remove debug comments
2018-11-18 11:35:04 -05:00
Hypolite Petovan ce075c80e6 Add statistics page
- Closes https://github.com/friendica/friendica-directory/issues/2
2018-11-18 10:38:43 -05:00
Hypolite Petovan e8752c7631 Restore full local name in settings
- Fallback to two-letter language code for translation if locale isn't found
- Rename L10n::langToString to L10n::localeToLanguageString
- Use setlocale() with the selected locale
2018-11-18 10:38:17 -05:00
Hypolite Petovan 012a3f9f8d Add poco retrieval during server poll
- Closes https://github.com/friendica/friendica-directory/issues/7
2018-11-18 10:36:03 -05:00
Hypolite Petovan 26b4299b68 [Composer] Add byjg/webrequest direct dependency 2018-11-18 10:32:42 -05:00
146 changed files with 9078 additions and 1518 deletions

View file

@ -4,7 +4,7 @@
1. Fork the repository 1. Fork the repository
2. Create a new branch for each feature or improvement 2. Create a new branch for each feature or improvement
3. Send a pull request from each feature branch to the master branch 3. Send a pull request from each feature branch to the stable branch
It is very important to separate new features or improvements into separate feature branches, and to send a It is very important to separate new features or improvements into separate feature branches, and to send a
pull request for each branch. This allows us to review and pull in new features or improvements individually. pull request for each branch. This allows us to review and pull in new features or improvements individually.

View file

@ -25,6 +25,15 @@ Please refer to the provided [installation instructions](INSTALL.md).
Please refer to the provided [update instructions](UPDATE.md). Please refer to the provided [update instructions](UPDATE.md).
## Custom pages
If you need to add custom HTML pages as required by law to publish any website processing data in some countries, simply add your HTML files in the `config/pages` folder, they will be automatically linked from the footer.
Tips:
- The expected extension is `.html`.
- Underscores in the page file name are replaced by spaces in the page link label.
- Accents aren't supported.
## See also ## See also
- [Project Concepts](docs/Concepts.md) - [Project Concepts](docs/Concepts.md)

View file

@ -1 +1 @@
2.1-rc2 2.4.2

BIN
bin/composer.phar Normal file

Binary file not shown.

View file

@ -15,9 +15,9 @@ require __DIR__ . '/../src/dependencies.php';
(new \Friendica\Directory\Controllers\Cron( (new \Friendica\Directory\Controllers\Cron(
$container->get('atlas'), $container->get('atlas'),
$container->get('\Friendica\Directory\Pollers\Profile'), $container->get(\Friendica\Directory\Pollers\Profile::class),
$container->get('\Friendica\Directory\Pollers\Server'), $container->get(\Friendica\Directory\Pollers\Server::class),
$container->get('\Friendica\Directory\Pollers\Directory'), $container->get(\Friendica\Directory\Pollers\Directory::class),
$container->get('logger') $container->get('logger')
))->execute(); ))->execute();

View file

@ -16,29 +16,33 @@
"ext-curl": "*", "ext-curl": "*",
"ext-gd": "*", "ext-gd": "*",
"ext-json": "*", "ext-json": "*",
"ext-pdo": "*",
"asika/simple-console": "^1.0", "asika/simple-console": "^1.0",
"atlas/pdo": "^1.1", "atlas/pdo": "^1.1",
"byjg/migration": "^2.1", "boronczyk/localization-middleware": "^1.4",
"fxp/composer-asset-plugin": "^1.4", "byjg/migration": "^4.0",
"byjg/uri": "^1.0.4",
"gettext/gettext": "^4.6",
"gofabian/negotiation-middleware": "dev-master",
"guzzlehttp/guzzle": "^6.5",
"laminas/laminas-escaper": "^2.6",
"laminas/laminas-zendframework-bridge": "^1.4",
"masterminds/html5": "^2.3", "masterminds/html5": "^2.3",
"monolog/monolog": "^1.17", "monolog/monolog": "^1.17",
"mrpetovan/net_ping": "^1.0", "mrpetovan/net_ping": "^1.2",
"sarahman/simple-filesystem-cache": "dev-master", "sarahman/simple-filesystem-cache": "^1.0",
"seld/cli-prompt": "^1.0", "seld/cli-prompt": "^1.0",
"slim/slim": "^3.1", "slim/slim": "^3.1",
"slim/php-view": "^2.0", "slim/php-view": "^2.0",
"zendframework/zend-escaper": "^2.6", "fxp/composer-asset-plugin": "^1.4",
"bower-asset/bootstrap.native": "^2.0", "bower-asset/bootstrap.native": "^2.0",
"bower-asset/fontawesome": "^5.5", "bower-asset/fontawesome": "^5.5"
"gofabian/negotiation-middleware": "^0.1.3",
"gettext/gettext": "^4.6",
"boronczyk/localization-middleware": "^1.4"
}, },
"require-dev": { "require-dev": {
"bower-asset/bootstrap": "^4.1", "bower-asset/bootstrap": "^4.1",
"phpunit/phpunit": ">=4.8 < 6.0", "phpunit/phpunit": ">=4.8 < 6.0",
"vimeo/psalm": "^2.0", "scssphp/scssphp": "^1.1",
"leafo/scssphp": "^0.7.7" "vimeo/psalm": "^2.0"
}, },
"autoload": { "autoload": {
"psr-4": { "psr-4": {
@ -51,6 +55,9 @@
} }
}, },
"config": { "config": {
"platform": {
"php": "7.3.0"
},
"process-timeout" : 0, "process-timeout" : 0,
"autoloader-suffix": "FriendicaDirectory", "autoloader-suffix": "FriendicaDirectory",
"optimize-autoloader": true, "optimize-autoloader": true,
@ -72,7 +79,8 @@
"/composer.*", "/composer.*",
"!/vendor", "!/vendor",
"public/assets/vendor", "public/assets/vendor",
"!public/assets/vendor/fontawesome/web-fonts-with-css", "!public/assets/vendor/fontawesome/css",
"!public/assets/vendor/fontawesome/webfonts",
"!public/assets/vendor/bootstrap.native/dist" "!public/assets/vendor/bootstrap.native/dist"
] ]
} }

2258
composer.lock generated

File diff suppressed because it is too large Load diff

4
config/.gitignore vendored
View file

@ -1,4 +1,6 @@
# Ignore everything in this directory # Ignore everything in this directory
* *
# Except this file # Except this file
!.gitignore !.gitignore
# And the pages subdirectory
!pages

4
config/pages/.gitignore vendored Normal file
View file

@ -0,0 +1,4 @@
# Ignore everything in this directory
*
# Except this file
!.gitignore

View file

@ -1,15 +1,26 @@
# Friendica Directory Protocol # Friendica Directory Protocol
## Surprise
```
GET /servers/surprise
```
Redirects to the base URL of a random server with open registration policy and above 75 health.
## Search ## Search
``` ```
GET /search[/account_type]?q=... GET /search[/account_type]?q=...[&page=...][&limit=...]
Accept: application/json Accept: application/json
``` ```
Parameters: URI Parameter:
- `account_type`: An arbitrary account type string. Currently supported are `all`, `people` and `forum`. Default is `all`. - `account_type` (optional): An arbitrary account type string. Expected values are `all`, `people`, `news`, `organization` and `group`. Default is `all`.
Query parameters:
- `q`: The search query. - `q`: The search query.
- `page` (optional): The page number, default is 1.
- `limit` (optional): The page size, default is 20, max is 100.
Returns a JSON structure containing a paginated list profiles matching the search query and the optional account type. Returns a JSON structure containing a paginated list profiles matching the search query and the optional account type.
@ -33,10 +44,46 @@ Example:
"region": "New York", "region": "New York",
"country": "USA", "country": "USA",
"profile_url": "https://friendica.mrpetovan.com/profile/hypolite", "profile_url": "https://friendica.mrpetovan.com/profile/hypolite",
"dfrn_request": "https://friendica.mrpetovan.com/dfrn_request/hypolite",
"photo": "https://friendica.mrpetovan.com/photo/27330388315ae4ed2b03e3c116980490-4.jpg?ts=1541567135", "photo": "https://friendica.mrpetovan.com/photo/27330388315ae4ed2b03e3c116980490-4.jpg?ts=1541567135",
"tags": "videogame gaming boardgame politics philosophy development programming php", "tags": "videogame gaming boardgame politics philosophy development programming php",
"last_activity": "2018-45" "last_activity": "2018-45",
"remote_follow": "https://friendica.mrpetovan.com/remote_follow/hypolite",
"subscribe": null
},
...
]
}
```
### Legacy interest match search
```
POST /msearch
Content-Type: application/x-www-form-urlencoded
Accept: application/json
```
Parameters:
- `s`: The search query, a list of tags separated by spaces or commas is expected.
- `p` (optional): The page number, default is 1.
- `n` (optional): The number of items per page, default is 80.
Returns a JSON structure containing a paginated list profiles matching the search query and the optional account type.
Example:
```json
{
"query": "videogame gaming boardgame politics philosophy development programming php",
"page": 1,
"items_page": 100,
"total": 32,
"results": [
{
"name": "Hyp🌧lite Pe☂ov🍃n (he/him)",
"url": "https://friendica.mrpetovan.com/profile/hypolite",
"photo": "https://friendica.mrpetovan.com/photo/27330388315ae4ed2b03e3c116980490-4.jpg?ts=1545521478",
"tags": "videogame gaming boardgame politics philosophy development programming php"
}, },
... ...
] ]

Binary file not shown.

Before

Width:  |  Height:  |  Size: 325 B

After

Width:  |  Height:  |  Size: 2.6 KiB

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Content;
/** /**
* The Pager has two very different output, Minimal and Full, see renderMinimal() and renderFull() for more details. * The Pager has two very different output, Minimal and Full, see renderMinimal() and renderFull() for more details.
* *
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Pager class Pager
{ {

View file

@ -0,0 +1,80 @@
<?php
namespace Friendica\Directory\Controllers\Api;
use Friendica\Directory\Content\Pager;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class MatchSearch
{
/**
* @var \Friendica\Directory\Models\Profile
*/
private $profileModel;
/**
* @var \Gettext\TranslatorInterface
*/
private $l10n;
public function __construct(
\Friendica\Directory\Models\Profile $profileModel,
\Gettext\TranslatorInterface $l10n
)
{
$this->profileModel = $profileModel;
$this->l10n = $l10n;
}
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{
$perpage = filter_input(INPUT_POST, 'n', FILTER_SANITIZE_NUMBER_INT);
$query = filter_input(INPUT_POST, 's', FILTER_SANITIZE_STRING);
if (!$perpage) {
$perpage = 80;
}
$pager = new Pager($this->l10n, $request, $perpage);
$pager->setPage(filter_input(INPUT_POST, 'p', FILTER_SANITIZE_NUMBER_INT));
$sql_where = "MATCH (p.`tags`) AGAINST (:query)";
// At sign (@) is a reserved symbol in InnoDB full-text search, it can't be escaped
$query = str_replace('@', ' ', $query);
$values = ['query' => $query];
$profiles = $this->profileModel->getListForDisplay(
null,
$pager->getItemsPerPage(),
$pager->getStart(),
$sql_where,
$values,
);
$results = [];
foreach ($profiles as $profile) {
$results[] = [
'name' => $profile['name'],
'url' => $profile['profile_url'],
'photo' => $profile['photo'],
'tags' => $profile['tags'],
];
}
$count = $this->profileModel->getCountForDisplay($sql_where, $values);
$vars = [
'query' => $query,
'page' => $pager->getPage(),
'items_page' => $pager->getItemsPerPage(),
'total' => $count,
'results' => $results
];
return $response->withJson($vars);
}
}

View file

@ -6,7 +6,7 @@ use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Photo class Photo
{ {
@ -14,12 +14,18 @@ class Photo
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
*/ */
private $atlas; private $atlas;
/**
* @var string
*/
private $defaultProfilePictureSmallPath;
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas \Atlas\Pdo\Connection $atlas,
string $defaultProfilePictureSmallPath
) )
{ {
$this->atlas = $atlas; $this->atlas = $atlas;
$this->defaultProfilePictureSmallPath = $defaultProfilePictureSmallPath;
} }
public function render(Request $request, Response $response, array $args): Response public function render(Request $request, Response $response, array $args): Response
@ -30,7 +36,7 @@ class Photo
); );
if (!$data) { if (!$data) {
$data = file_get_contents('public/images/default-profile-sm.jpg'); $data = file_get_contents($this->defaultProfilePictureSmallPath);
} }
//Try and cache our result. //Try and cache our result.

View file

@ -2,20 +2,15 @@
namespace Friendica\Directory\Controllers\Api; namespace Friendica\Directory\Controllers\Api;
use \Friendica\Directory\Content\Pager; use Friendica\Directory\Content\Pager;
use PDO;
use Psr\Http\Message\ResponseInterface; use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface; use Psr\Http\Message\ServerRequestInterface;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Search class Search
{ {
/**
* @var \Atlas\Pdo\Connection
*/
private $atlas;
/** /**
* @var \Friendica\Directory\Models\Profile * @var \Friendica\Directory\Models\Profile
*/ */
@ -26,19 +21,19 @@ class Search
private $l10n; private $l10n;
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas,
\Friendica\Directory\Models\Profile $profileModel, \Friendica\Directory\Models\Profile $profileModel,
\Gettext\TranslatorInterface $l10n \Gettext\TranslatorInterface $l10n
) )
{ {
$this->atlas = $atlas;
$this->profileModel = $profileModel; $this->profileModel = $profileModel;
$this->l10n = $l10n; $this->l10n = $l10n;
} }
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{ {
$pager = new Pager($this->l10n, $request, 20); $limit = min(100, filter_input(INPUT_GET, 'limit', FILTER_SANITIZE_NUMBER_INT) ?: 20);
$pager = new Pager($this->l10n, $request, $limit);
$originalQuery = $query = filter_input(INPUT_GET, 'q'); $originalQuery = $query = filter_input(INPUT_GET, 'q');
@ -48,8 +43,10 @@ class Search
$query .= '%'; $query .= '%';
$sql_where = '`' . $field . '` LIKE :query'; $sql_where = '`' . $field . '` LIKE :query';
} else { } else {
$sql_where = "MATCH (p.`name`, p.`pdesc`, p.`profile_url`, p.`locality`, p.`region`, p.`country`, p.`tags` ) $sql_where = "MATCH (p.`name`, p.`pdesc`, p.`username`, p.`locality`, p.`region`, p.`country`, p.`tags` )
AGAINST (:query IN BOOLEAN MODE)"; AGAINST (:query IN BOOLEAN MODE)";
// At sign (@) is a reserved symbol in InnoDB full-text search, it can't be escaped
$query = str_replace('@', ' ', $query);
} }
$values = ['query' => $query]; $values = ['query' => $query];
@ -61,7 +58,13 @@ AND `account_type` = :account_type';
$values['account_type'] = $account_type; $values['account_type'] = $account_type;
} }
$profiles = $this->profileModel->getListForDisplay($pager->getItemsPerPage(), $pager->getStart(), $sql_where, $values); $profiles = $this->profileModel->getListForDisplay(
null,
$pager->getItemsPerPage(),
$pager->getStart(),
$sql_where,
$values,
);
$count = $this->profileModel->getCountForDisplay($sql_where, $values); $count = $this->profileModel->getCountForDisplay($sql_where, $values);
@ -74,7 +77,6 @@ AND `account_type` = :account_type';
'profiles' => $profiles 'profiles' => $profiles
]; ];
// Render index view
return $response->withJson($vars); return $response->withJson($vars);
} }
} }

View file

@ -6,7 +6,7 @@ use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Submit class Submit
{ {

View file

@ -0,0 +1,45 @@
<?php
namespace Friendica\Directory\Controllers\Api;
use Friendica\Directory\Content\Pager;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Surprise
{
/**
* @var \Atlas\Pdo\Connection
*/
private $atlas;
public function __construct(
\Atlas\Pdo\Connection $atlas
)
{
$this->atlas = $atlas;
}
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{
$redirectUrl = '';
$sql = 'SELECT `base_url`, server.*
FROM `server`
WHERE `reg_policy` = "REGISTER_OPEN"
AND `health_score` > 75
AND `ssl_state`
AND `available`
ORDER BY `health_score` DESC, RAND()';
$server = $this->atlas->fetchOne($sql);
if ($server) {
$redirectUrl = $server['base_url'];
}
return $response->withRedirect($redirectUrl);
}
}

View file

@ -6,7 +6,7 @@ use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class SyncPull class SyncPull
{ {

View file

@ -7,7 +7,7 @@ use Monolog\Logger;
/** /**
* Description of Console * Description of Console
* *
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Console extends \Asika\SimpleConsole\Console class Console extends \Asika\SimpleConsole\Console
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class DirectoryAdd extends \Asika\SimpleConsole\Console class DirectoryAdd extends \Asika\SimpleConsole\Console
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class DirectoryPoll extends \Asika\SimpleConsole\Console class DirectoryPoll extends \Asika\SimpleConsole\Console
{ {

View file

@ -2,28 +2,27 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
use Friendica\Directory\Utils\L10n;
use Gettext\Merge; use Gettext\Merge;
use Gettext\Translations; use Gettext\Translations;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ExtractStrings extends \Asika\SimpleConsole\Console class ExtractStrings extends \Asika\SimpleConsole\Console
{ {
/** /**
* @var array * @var string
*/ */
protected $locales; protected $translationPath;
protected $helpOptions = ['h', 'help', '?']; protected $helpOptions = ['h', 'help', '?'];
public function __construct( public function __construct(
array $locales, string $translationPath,
?array $argv = null ?array $argv = null
) )
{ {
$this->locales = $locales; $this->translationPath = $translationPath;
parent::__construct($argv); parent::__construct($argv);
} }
@ -39,7 +38,7 @@ Description
Extract translation strings Extract translation strings
Options Options
--all Generate po files for all available languages --all Update PO files for all existing languages
--force Generate po file from scratch, discarding existing translations --force Generate po file from scratch, discarding existing translations
-h|--help|-? Show help information -h|--help|-? Show help information
-v Show more debug information. -v Show more debug information.
@ -54,7 +53,7 @@ HELP;
} }
if ($this->getOption('all')) { if ($this->getOption('all')) {
$langs = $this->locales; $langs = array_map('basename', glob(realpath($this->translationPath) . '/*', GLOB_ONLYDIR));
} else { } else {
$lang = $this->getArgument(0); $lang = $this->getArgument(0);
if (!$lang) { if (!$lang) {
@ -63,8 +62,6 @@ HELP;
$langs = [$lang]; $langs = [$lang];
} }
$outputDir = __DIR__ . '/../../../lang';
$dir_iterator = new \RecursiveDirectoryIterator(realpath(__DIR__ . '/../../../'), \FilesystemIterator::SKIP_DOTS); $dir_iterator = new \RecursiveDirectoryIterator(realpath(__DIR__ . '/../../../'), \FilesystemIterator::SKIP_DOTS);
$iterator = new \RecursiveIteratorIterator($dir_iterator, \RecursiveIteratorIterator::SELF_FIRST); $iterator = new \RecursiveIteratorIterator($dir_iterator, \RecursiveIteratorIterator::SELF_FIRST);
@ -88,31 +85,20 @@ HELP;
foreach ($langs as $locale) { foreach ($langs as $locale) {
$existingTranslations = new Translations(); $existingTranslations = new Translations();
$stringsPoFile = $outputDir . '/' . $locale . '/LC_MESSAGES/strings.po'; $stringsPoFile = $this->translationPath . '/' . $locale . '/LC_MESSAGES/strings.po';
if (is_file($stringsPoFile)) { if (is_file($stringsPoFile)) {
if (!$this->getOption('force')) { if (!$this->getOption('force')) {
$this->out('Loading existing ' . $locale . ' translations'); $this->out('Loading existing ' . $locale . ' translations');
$existingTranslations->addFromPoFile($stringsPoFile); $existingTranslations->addFromPoFile($stringsPoFile);
} }
} else { } else {
mkdir(dirname($stringsPoFile), true); $this->out('Creating directory ' . dirname($stringsPoFile));
mkdir(dirname($stringsPoFile), 0755, true);
} }
// $existingPoFile = $outputDir . '/' . $locale . '/LC_MESSAGES/existing.po';
// $existingPoString = $existingTranslations->toPoString();
// $existingPoString = str_replace(realpath(__DIR__ . '/../../../../') . DIRECTORY_SEPARATOR, '', $existingPoString);
// $this->out('Writing ' . realpath($existingPoFile));
// file_put_contents($existingPoFile, $existingPoString);
// $updatedPoFile = $outputDir . '/' . $locale . '/LC_MESSAGES/updated.po';
// $updatedPoString = $updatedTranslations->toPoString();
// $updatedPoString = str_replace(realpath(__DIR__ . '/../../../../') . DIRECTORY_SEPARATOR, '', $updatedPoString);
// $this->out('Writing ' . realpath($updatedPoFile));
// file_put_contents($updatedPoFile, $updatedPoString);
$updatedTranslations->setLanguage($locale); $updatedTranslations->setLanguage($locale);
if ($this->getOption('force')) { if ($this->getOption('force') || !is_file($stringsPoFile)) {
$existingTranslations = $updatedTranslations; $existingTranslations = $updatedTranslations;
} else { } else {
$this->out('Merging with existing translations'); $this->out('Merging with existing translations');

View file

@ -7,7 +7,7 @@ use Monolog\Logger;
use Seld\CliPrompt\CliPrompt; use Seld\CliPrompt\CliPrompt;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Install extends \Asika\SimpleConsole\Console class Install extends \Asika\SimpleConsole\Console
{ {
@ -31,9 +31,9 @@ class Install extends \Asika\SimpleConsole\Console
protected function getHelp() protected function getHelp()
{ {
$help = <<<HELP $help = <<<HELP
console install - Install directory console install - Install wizard
Usage Usage
bin/console install <server_url> [-h|--help|-?] [-v] bin/console install [-h|--help|-?] [-v]
Description Description
Install directory Install directory

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Controllers\Console;
use Friendica\Directory\Models\ProfilePollQueue; use Friendica\Directory\Models\ProfilePollQueue;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfileAdd extends \Asika\SimpleConsole\Console class ProfileAdd extends \Asika\SimpleConsole\Console
{ {

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Controllers\Console;
use Friendica\Directory\Models\Profile; use Friendica\Directory\Models\Profile;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfileHide extends \Asika\SimpleConsole\Console class ProfileHide extends \Asika\SimpleConsole\Console
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfilePoll extends \Asika\SimpleConsole\Console class ProfilePoll extends \Asika\SimpleConsole\Console
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ServerHide extends \Asika\SimpleConsole\Console class ServerHide extends \Asika\SimpleConsole\Console
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers\Console; namespace Friendica\Directory\Controllers\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ServerPoll extends \Asika\SimpleConsole\Console class ServerPoll extends \Asika\SimpleConsole\Console
{ {

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Controllers\Console;
use Monolog\Logger; use Monolog\Logger;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class UpdateDb extends \Asika\SimpleConsole\Console class UpdateDb extends \Asika\SimpleConsole\Console
{ {
@ -37,12 +37,14 @@ class UpdateDb extends \Asika\SimpleConsole\Console
$help = <<<HELP $help = <<<HELP
console updatedb - Update database schema console updatedb - Update database schema
Usage Usage
bin/console updatedb <server_url> [-h|--help|-?] [-v] bin/console updatedb [<version>] [-h|--help|-?] [-v]
Description Description
Update database schema Update database schema
Options Options
<version> Optional target version number, default is the latest version.
Do not use this parameter if you're not sure what you're doing, it will result in data loss!
-h|--help|-? Show help information -h|--help|-? Show help information
-v Show more debug information. -v Show more debug information.
HELP; HELP;
@ -56,16 +58,38 @@ HELP;
return 0; return 0;
} }
if (count($this->args) > 1) { if (count($this->args) > 2) {
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments'); throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
} }
$this->out('Updating database schema to latest version...'); $currentVersion = $this->migration->getCurrentVersion()['version'];
$this->migration->up(); $this->out('Database schema currently in version ' . $currentVersion);
$this->out('Database schema migrated to version ' . $this->migration->getCurrentVersion()['version']); if (count($this->args) == 1) {
$this->out('Updating database schema to latest version...');
$this->migration->up();
$this->out('Database schema migrated to version ' . $this->migration->getCurrentVersion()['version']);
return 0;
}
$target = $this->getArgument(1);
if ($target > $currentVersion) {
$this->out('Updating database schema to version ' . $target);
$this->migration->up($target);
$this->out('Database schema migrated up to version ' . $this->migration->getCurrentVersion()['version']);
return 0;
}
if ($target < $currentVersion) {
$this->out('Downgrading database schema to version ' . $target);
$this->migration->down($target);
$this->out('Database schema migrated down to version ' . $this->migration->getCurrentVersion()['version']);
return 0;
}
$this->out('Target version equal to current version, exiting.');
return 0; return 0;
} }
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Controllers; namespace Friendica\Directory\Controllers;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Cron class Cron
{ {

View file

@ -5,5 +5,5 @@ namespace Friendica\Directory\Controllers\Web;
abstract class BaseController abstract class BaseController
{ {
abstract function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): array;
} }

View file

@ -4,13 +4,13 @@ namespace Friendica\Directory\Controllers\Web;
use Friendica\Directory\Content\Pager; use Friendica\Directory\Content\Pager;
use Friendica\Directory\Views\Widget\PopularCountries; use Friendica\Directory\Views\Widget\PopularCountries;
use Friendica\Directory\Views\Widget\PopularLanguages; use Friendica\Directory\Views\Widget\PopularProfileLanguages;
use Friendica\Directory\Views\Widget\PopularTags; use Friendica\Directory\Views\Widget\PopularTags;
use Slim\Http\Request; use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Directory extends BaseController class Directory extends BaseController
{ {
@ -18,6 +18,10 @@ class Directory extends BaseController
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
*/ */
private $atlas; private $atlas;
/**
* @var \Friendica\Directory\Models\Server
*/
private $serverModel;
/** /**
* @var \Friendica\Directory\Models\Profile * @var \Friendica\Directory\Models\Profile
*/ */
@ -37,6 +41,7 @@ class Directory extends BaseController
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas, \Atlas\Pdo\Connection $atlas,
\Friendica\Directory\Models\Server $serverModel,
\Friendica\Directory\Models\Profile $profileModel, \Friendica\Directory\Models\Profile $profileModel,
\Friendica\Directory\Views\Widget\AccountTypeTabs $accountTypeTabs, \Friendica\Directory\Views\Widget\AccountTypeTabs $accountTypeTabs,
\Friendica\Directory\Views\PhpRenderer $renderer, \Friendica\Directory\Views\PhpRenderer $renderer,
@ -44,6 +49,7 @@ class Directory extends BaseController
) )
{ {
$this->atlas = $atlas; $this->atlas = $atlas;
$this->serverModel = $serverModel;
$this->profileModel = $profileModel; $this->profileModel = $profileModel;
$this->accountTypeTabs = $accountTypeTabs; $this->accountTypeTabs = $accountTypeTabs;
$this->renderer = $renderer; $this->renderer = $renderer;
@ -54,20 +60,26 @@ class Directory extends BaseController
{ {
$popularTags = new PopularTags($this->atlas, $this->renderer); $popularTags = new PopularTags($this->atlas, $this->renderer);
$popularCountries = new PopularCountries($this->atlas, $this->renderer); $popularCountries = new PopularCountries($this->atlas, $this->renderer);
$popularLanguages = new PopularLanguages($this->atlas, $this->renderer); $popularLanguages = new PopularProfileLanguages($this->atlas, $this->renderer);
$pager = new Pager($this->l10n, $request, 20); $pager = new Pager($this->l10n, $request, 20);
$condition = ''; $sql_where = '';
$values = []; $values = [];
if (!empty($args['account_type'])) { if (!empty($args['account_type'])) {
$condition = '`account_type` = :account_type'; $sql_where = '`account_type` = :account_type';
$values = ['account_type' => $args['account_type']]; $values = ['account_type' => $args['account_type']];
} }
$profiles = $this->profileModel->getListForDisplay($pager->getItemsPerPage(), $pager->getStart(), $condition, $values); $profiles = $this->profileModel->getListForDisplay(
$this->serverModel->getSubscribeUrlByProfile($request->getQueryParam('zrl', '')),
$pager->getItemsPerPage(),
$pager->getStart(),
$sql_where,
$values,
);
$count = $this->profileModel->getCountForDisplay($condition, $values); $count = $this->profileModel->getCountForDisplay($sql_where, $values);
$vars = [ $vars = [
'title' => $this->l10n->gettext('People'), 'title' => $this->l10n->gettext('People'),
@ -82,7 +94,6 @@ class Directory extends BaseController
$content = $this->renderer->fetch('directory.phtml', $vars); $content = $this->renderer->fetch('directory.phtml', $vars);
// Render index view
return ['content' => $content]; return ['content' => $content];
} }
} }

View file

@ -0,0 +1,28 @@
<?php
namespace Friendica\Directory\Controllers\Web;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Page extends BaseController
{
/**
* @var string
*/
private $pageFile;
public function __construct(
string $pageFile
)
{
$this->pageFile = $pageFile;
}
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): array
{
$content = file_get_contents($this->pageFile);
return ['content' => $content];
}
}

View file

@ -3,12 +3,9 @@
namespace Friendica\Directory\Controllers\Web; namespace Friendica\Directory\Controllers\Web;
use \Friendica\Directory\Content\Pager; use \Friendica\Directory\Content\Pager;
use PDO;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Search extends BaseController class Search extends BaseController
{ {
@ -16,6 +13,10 @@ class Search extends BaseController
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
*/ */
private $atlas; private $atlas;
/**
* @var \Friendica\Directory\Models\Server
*/
private $serverModel;
/** /**
* @var \Friendica\Directory\Models\Profile * @var \Friendica\Directory\Models\Profile
*/ */
@ -35,6 +36,7 @@ class Search extends BaseController
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas, \Atlas\Pdo\Connection $atlas,
\Friendica\Directory\Models\Server $serverModel,
\Friendica\Directory\Models\Profile $profileModel, \Friendica\Directory\Models\Profile $profileModel,
\Friendica\Directory\Views\Widget\AccountTypeTabs $accountTypeTabs, \Friendica\Directory\Views\Widget\AccountTypeTabs $accountTypeTabs,
\Friendica\Directory\Views\PhpRenderer $renderer, \Friendica\Directory\Views\PhpRenderer $renderer,
@ -42,6 +44,7 @@ class Search extends BaseController
) )
{ {
$this->atlas = $atlas; $this->atlas = $atlas;
$this->serverModel = $serverModel;
$this->profileModel = $profileModel; $this->profileModel = $profileModel;
$this->accountTypeTabs = $accountTypeTabs; $this->accountTypeTabs = $accountTypeTabs;
$this->renderer = $renderer; $this->renderer = $renderer;
@ -50,11 +53,14 @@ class Search extends BaseController
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): array public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): array
{ {
$pager = new Pager($this->l10n, $request, 20); $limit = min(100, filter_input(INPUT_GET, 'limit', FILTER_SANITIZE_NUMBER_INT) ?: 20);
$originalQuery = $query = filter_input(INPUT_GET, 'q'); $pager = new Pager($this->l10n, $request, $limit);
$field = filter_input(INPUT_GET, 'field', FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_LOW & FILTER_FLAG_STRIP_HIGH); $originalQuery = $query = $request->getParam('q', '');
$field = $request->getParam('field', '');
$field = filter_var($field, FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_LOW | FILTER_FLAG_STRIP_HIGH | FILTER_FLAG_STRIP_BACKTICK);
$fieldName = ''; $fieldName = '';
@ -71,13 +77,14 @@ class Search extends BaseController
} }
} else { } else {
$sql_where = "MATCH (p.`name`, p.`pdesc`, p.`profile_url`, p.`locality`, p.`region`, p.`country`, p.`tags` ) $sql_where = "MATCH (p.`name`, p.`pdesc`, p.`username`, p.`locality`, p.`region`, p.`country`, p.`tags` )
AGAINST (:query IN BOOLEAN MODE)"; AGAINST (:query IN BOOLEAN MODE)";
// At sign (@) is a reserved symbol in InnoDB full-text search, it can't be escaped
$query = str_replace('@', ' ', $query);
} }
$values = ['query' => $query]; $values = ['query' => $query];
$account_type = $args['account_type'] ?? ''; $account_type = $args['account_type'] ?? '';
$accountTypeTabs = $this->accountTypeTabs->render('search', $account_type, $sql_where, $values, ['q' => $originalQuery, 'field' => $field]); $accountTypeTabs = $this->accountTypeTabs->render('search', $account_type, $sql_where, $values, ['q' => $originalQuery, 'field' => $field]);
@ -88,7 +95,13 @@ AND `account_type` = :account_type';
$values['account_type'] = $account_type; $values['account_type'] = $account_type;
} }
$profiles = $this->profileModel->getListForDisplay($pager->getItemsPerPage(), $pager->getStart(), $sql_where, $values); $profiles = $this->profileModel->getListForDisplay(
$this->serverModel->getSubscribeUrlByProfile($request->getQueryParam('zrl', '')),
$pager->getItemsPerPage(),
$pager->getStart(),
$sql_where,
$values,
);
$count = $this->profileModel->getCountForDisplay($sql_where, $values); $count = $this->profileModel->getCountForDisplay($sql_where, $values);
@ -105,7 +118,6 @@ AND `account_type` = :account_type';
$content = $this->renderer->fetch('search.phtml', $vars); $content = $this->renderer->fetch('search.phtml', $vars);
// Render index view
return ['content' => $content, 'noNavSearch' => true]; return ['content' => $content, 'noNavSearch' => true];
} }
} }

View file

@ -2,13 +2,14 @@
namespace Friendica\Directory\Controllers\Web; namespace Friendica\Directory\Controllers\Web;
use \Friendica\Directory\Content\Pager; use Friendica\Directory\Content\Pager;
use Friendica\Directory\Views\Widget\PopularServerLanguages;
use PDO; use PDO;
use Slim\Http\Request; use Slim\Http\Request;
use Slim\Http\Response; use Slim\Http\Response;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Servers extends BaseController class Servers extends BaseController
{ {
@ -42,11 +43,11 @@ class Servers extends BaseController
$this->simplecache = $simplecache; $this->simplecache = $simplecache;
} }
public function render(Request $request, Response $response): array public function render(Request $request, Response $response, array $args): array
{ {
$stable_version = $this->simplecache->get('stable_version'); $stable_version = $this->simplecache->get('stable_version');
if (!$stable_version) { if (!$stable_version) {
$stable_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/master/VERSION')); $stable_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/stable/VERSION'));
$this->simplecache->set('stable_version', $stable_version); $this->simplecache->set('stable_version', $stable_version);
} }
@ -56,19 +57,34 @@ class Servers extends BaseController
$this->simplecache->set('dev_version', $dev_version); $this->simplecache->set('dev_version', $dev_version);
} }
$rc_version = str_replace('-dev', '-rc', $dev_version);
$popularLanguages = new PopularServerLanguages($this->atlas, $this->renderer);
$pager = new Pager($this->l10n, $request, 20); $pager = new Pager($this->l10n, $request, 20);
$sql_where = '';
$values = [];
if (!empty($args['language'])) {
$sql_where .= '
AND LEFT(`language`, 2) = LEFT(:language, 2)';
$values['language'] = $args['language'];
}
$stmt = 'SELECT * $stmt = 'SELECT *
FROM `server` s FROM `server` s
WHERE `reg_policy` = "REGISTER_OPEN" WHERE `reg_policy` != "REGISTER_CLOSED"
AND `available` AND `available`
AND NOT `hidden` AND NOT `hidden`
' . $sql_where . '
ORDER BY `health_score` DESC, `ssl_state` DESC, `info` != "" DESC, `last_seen` DESC ORDER BY `health_score` DESC, `ssl_state` DESC, `info` != "" DESC, `last_seen` DESC
LIMIT :start, :limit'; LIMIT :start, :limit';
$servers = $this->atlas->fetchAll($stmt, [ $listValues = array_merge($values, [
'start' => [$pager->getStart(), PDO::PARAM_INT], 'start' => [$pager->getStart(), PDO::PARAM_INT],
'limit' => [$pager->getItemsPerPage(), PDO::PARAM_INT] 'limit' => [$pager->getItemsPerPage(), PDO::PARAM_INT]
]); ]);
$servers = $this->atlas->fetchAll($stmt, $listValues);
foreach ($servers as $key => $server) { foreach ($servers as $key => $server) {
$servers[$key]['user_count'] = $this->atlas->fetchValue( $servers[$key]['user_count'] = $this->atlas->fetchValue(
@ -79,17 +95,22 @@ LIMIT :start, :limit';
$stmt = 'SELECT COUNT(*) $stmt = 'SELECT COUNT(*)
FROM `server` s FROM `server` s
WHERE `reg_policy` = "REGISTER_OPEN" WHERE `reg_policy` != "REGISTER_CLOSED"
AND `available` AND `available`
AND NOT `hidden`'; AND NOT `hidden`
$count = $this->atlas->fetchValue($stmt); ' . $sql_where;
$count = $this->atlas->fetchValue($stmt, $values);
$vars = [ $vars = [
'title' => $this->l10n->gettext('Public Servers'), 'title' => $this->l10n->gettext('Public Servers'),
'total' => $count,
'language' => $args['language'] ?? null,
'servers' => $servers, 'servers' => $servers,
'pager' => $pager->renderFull($count), 'pager' => $pager->renderFull($count),
'stable_version' => $stable_version, 'stable_version' => $stable_version,
'rc_version' => $rc_version,
'dev_version' => $dev_version, 'dev_version' => $dev_version,
'popularLanguages' => $popularLanguages->render(),
]; ];
$content = $this->renderer->fetch('servers.phtml', $vars); $content = $this->renderer->fetch('servers.phtml', $vars);

View file

@ -0,0 +1,159 @@
<?php
namespace Friendica\Directory\Controllers\Web;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Statistics extends BaseController
{
/**
* @var \Atlas\Pdo\Connection
*/
private $connection;
/**
* @var \Psr\SimpleCache\CacheInterface
*/
private $simplecache;
/**
* @var \Friendica\Directory\Views\PhpRenderer
*/
private $renderer;
public function __construct(
\Atlas\Pdo\Connection $atlas,
\Psr\SimpleCache\CacheInterface $simplecache,
\Friendica\Directory\Views\PhpRenderer $renderer
)
{
$this->connection = $atlas;
$this->simplecache = $simplecache;
$this->renderer = $renderer;
}
public function render(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): array
{
$profilePollQueueCount = $this->connection->fetchValue('SELECT COUNT(*) FROM `profile_poll_queue`');
$profileCounts = $this->connection->fetchOne(
'SELECT
COUNT(*) AS `total`,
SUM(CASE WHEN `available` THEN 1 ELSE 0 END) AS `available`,
SUM(CASE WHEN `language` IS NOT NULL THEN 1 ELSE 0 END) AS `language`
FROM `profile`
WHERE NOT `hidden`');
$stmt = 'SELECT `language`, COUNT(*) AS `total`, COUNT(*) / :total AS `ratio`
FROM `profile`
WHERE `language` IS NOT NULL
AND `available`
AND NOT `hidden`
GROUP BY `language`
ORDER BY `total` DESC';
$profileLanguages = $this->connection->fetchAll($stmt, ['total' => $profileCounts['language']]);
$stable_version = $this->simplecache->get('stable_version');
if (!$stable_version) {
$stable_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/stable/VERSION'));
$this->simplecache->set('stable_version', $stable_version);
}
$dev_version = $this->simplecache->get('dev_version');
if (!$dev_version) {
$dev_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/develop/VERSION'));
$this->simplecache->set('dev_version', $dev_version);
}
$rc_version = str_replace('-dev', '-rc', $dev_version);
$serverPollQueueCount = $this->connection->fetchValue('SELECT COUNT(*) FROM `server_poll_queue`');
$serverCounts = $this->connection->fetchOne(
'SELECT
COUNT(*) AS `total`,
SUM(CASE WHEN `available` THEN 1 ELSE 0 END) AS `available`,
SUM(CASE WHEN `available` AND `language` IS NOT NULL THEN 1 ELSE 0 END) AS `language`,
SUM(CASE WHEN `available` AND `reg_policy` != "REGISTER_CLOSED" THEN 1 ELSE 0 END) AS `open`,
SUM(CASE WHEN `available` AND `version` IS NOT NULL THEN 1 ELSE 0 END) AS `version`,
SUM(CASE WHEN `available` AND (`version` = :dev_version OR `version` = :rc_version) THEN 1 ELSE 0 END) AS `dev_version`,
SUM(CASE WHEN `available` AND `version` = :stable_version THEN 1 ELSE 0 END) AS `stable_version`,
SUM(CASE WHEN `available` AND `version` != :dev_version AND `version` != :stable_version AND `version` != :rc_version THEN 1 ELSE 0 END) AS `outdated_version`
FROM `server`
WHERE NOT `hidden`', ['dev_version' => $dev_version, 'rc_version' => $rc_version, 'stable_version' => $stable_version]);
$stmt = 'SELECT LEFT(`language`, 2) AS `language`, COUNT(*) AS `total`, COUNT(*) / :total AS `ratio`
FROM `server`
WHERE `language` IS NOT NULL
AND `available`
AND NOT `hidden`
GROUP BY LEFT(`language`, 2)
ORDER BY `total` DESC';
$serverLanguages = $this->connection->fetchAll($stmt, ['total' => $serverCounts['language']]);
$stmt = 'SELECT `version`, COUNT(*) AS `total`, COUNT(*) / :total AS `ratio`
FROM `server`
WHERE `version` IS NOT NULL
AND `available`
AND NOT `hidden`
GROUP BY `version`
ORDER BY `total` DESC';
$serverVersions = $this->connection->fetchAll($stmt, ['total' => $serverCounts['version']]);
$vars = [
'stats' => [
'profile_queue' => [
'total' => $profilePollQueueCount
],
'profile' => [
'total' => $profileCounts['total'],
'ratio' => $profileCounts['total'] / $profilePollQueueCount,
'available' => [
'total' => $profileCounts['available'],
'ratio' => $profileCounts['available'] / $profileCounts['total']
],
'language' => [
'total' => $profileCounts['language'],
'ratio' => $profileCounts['language'] / $profileCounts['available']
],
'languages' => $profileLanguages,
],
'server_queue' => [
'total' => $serverPollQueueCount
],
'server' => [
'total' => $serverCounts['total'],
'ratio' => $serverCounts['total'] / $serverPollQueueCount,
'available' => [
'total' => $serverCounts['available'],
'ratio' => $serverCounts['available'] / $serverCounts['total']
],
'language' => [
'total' => $serverCounts['language'],
'ratio' => $serverCounts['language'] / $serverCounts['available']
],
'open' => [
'total' => $serverCounts['open'],
'ratio' => $serverCounts['open'] / $serverCounts['available']
],
'version' => [
'total' => $serverCounts['version'],
'ratio' => $serverCounts['version'] / $serverCounts['available']
],
'languages' => $serverLanguages,
'versions' => $serverVersions,
],
],
'dev_version' => $dev_version,
'rc_version' => $rc_version,
'stable_version' => $stable_version,
];
$content = $this->renderer->fetch('statistics.phtml', $vars);
// Render index view
return ['content' => $content, 'noNavSearch' => true];
}
}

View file

@ -0,0 +1,40 @@
<?php
namespace Friendica\Directory\Middleware;
use Friendica\Directory\Views\PhpRenderer;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
/**
* The ZRL middleware ensures the Renderer ZRL attribute is set if the query string parameter is present
*
* @author Hypolite Petovan <hypolite@mrpetovan.com>
* @package Friendica\Directory\Middleware
*/
class ZrlMiddleware
{
/**
* @var PhpRenderer
*/
private $phpRenderer;
public function __construct(PhpRenderer $phpRenderer)
{
$this->phpRenderer = $phpRenderer;
}
/**
* @param ServerRequestInterface $request PSR7 request
* @param ResponseInterface $response PSR7 response
* @param callable $next Next middleware
*
* @return ResponseInterface
*/
public function __invoke(ServerRequestInterface $request, ResponseInterface $response, callable $next)
{
$this->phpRenderer->addAttribute('zrl', $request->getQueryParams()['zrl'] ?? null);
return $next($request, $response);
}
}

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory; namespace Friendica\Directory;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Model class Model
{ {

View file

@ -3,10 +3,17 @@
namespace Friendica\Directory\Models; namespace Friendica\Directory\Models;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Profile extends \Friendica\Directory\Model class Profile extends \Friendica\Directory\Model
{ {
const ACCOUNT_TYPE_PERSON = 0;
const ACCOUNT_TYPE_ORGANISATION = 1;
const ACCOUNT_TYPE_NEWS = 2;
const ACCOUNT_TYPE_COMMUNITY = 3;
const ACCOUNT_TYPE_RELAY = 4;
const ACCOUNT_TYPE_DELETED = 127;
public function deleteById(int $profile_id): bool public function deleteById(int $profile_id): bool
{ {
$this->atlas->perform('DELETE FROM `photo` WHERE `profile_id` = :profile_id', $this->atlas->perform('DELETE FROM `photo` WHERE `profile_id` = :profile_id',
@ -74,7 +81,7 @@ class Profile extends \Friendica\Directory\Model
]; ];
} }
public function getListForDisplay(int $limit = 30, int $start = 0, string $condition = '', array $values = []): array public function getListForDisplay(string $subscribeUrl = null, int $limit = 30, int $start = 0, string $condition = '', array $values = []): array
{ {
if ($condition) { if ($condition) {
$condition = 'AND ' . $condition; $condition = 'AND ' . $condition;
@ -86,18 +93,24 @@ class Profile extends \Friendica\Directory\Model
]); ]);
$stmt = 'SELECT p.`id`, p.`name`, p.`username`, p.`addr`, p.`account_type`, p.`language`, $stmt = 'SELECT p.`id`, p.`name`, p.`username`, p.`addr`, p.`account_type`, p.`language`,
p.`pdesc`, p.`locality`, p.`region`, p.`country`, p.`profile_url`, p.`dfrn_request`, p.`pdesc`, p.`locality`, p.`region`, p.`country`, p.`profile_url`,
p.`photo`, p.`tags`, p.`last_activity` p.`photo`, p.`tags`, p.`last_activity`, s.`version`
FROM `profile` p FROM `profile` p
JOIN `server` s ON s.`id` = p.`server_id` AND s.`available` AND NOT s.`hidden` JOIN `server` s ON s.`id` = p.`server_id` AND s.`available` AND NOT s.`hidden`
WHERE p.`available` WHERE p.`available`
AND NOT p.`hidden` AND NOT p.`hidden`
' . $condition . ' ' . $condition . '
GROUP BY p.`id` GROUP BY p.`id`, `filled_fields`, `last_activity`, `updated`
ORDER BY `filled_fields` DESC, `last_activity` DESC, `updated` DESC ORDER BY `filled_fields` DESC, `last_activity` DESC, `updated` DESC
LIMIT :start, :limit'; LIMIT :start, :limit';
$profiles = $this->atlas->fetchAll($stmt, $values); $profiles = $this->atlas->fetchAll($stmt, $values);
array_walk($profiles, function (array &$profile) use ($subscribeUrl) {
$profile['remote_follow'] = version_compare($profile['version'], '2020.03', '>=') ? str_replace('/profile/', '/remote_follow/', $profile['profile_url']) : null;
$profile['subscribe'] = $subscribeUrl ? str_replace('{uri}', urlencode($profile['profile_url']), $subscribeUrl): null;
unset($profile['version']);
});
return $profiles; return $profiles;
} }

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Models;
use Friendica\Directory\Utils\Network; use Friendica\Directory\Utils\Network;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfilePollQueue extends \Friendica\Directory\Model class ProfilePollQueue extends \Friendica\Directory\Model
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Models; namespace Friendica\Directory\Models;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Server extends \Friendica\Directory\Model class Server extends \Friendica\Directory\Model
{ {
@ -33,10 +33,28 @@ class Server extends \Friendica\Directory\Model
SET `server_id` = :server_id, SET `server_id` = :server_id,
`alias` = :alias, `alias` = :alias,
`timestamp` = NOW() `timestamp` = NOW()
ON DUPLICATE KEY UPDATE `timestamp` = NOW()', ON DUPLICATE KEY UPDATE
`server_id` = :server_id,
`timestamp` = NOW()',
[ [
'server_id' => $server_id, 'server_id' => $server_id,
'alias' => strtolower($server_alias) 'alias' => strtolower($server_alias)
]); ]);
} }
/**
* Returns the complete subscribe URL of the given profile URL if we have it for the related server
*
* @param string $profile_url
* @return mixed|null
*/
public function getSubscribeUrlByProfile(string $profile_url)
{
if (preg_match('#^(.+)/profile/#', $profile_url, $matches)) {
$server = $this->getByUrlAlias($matches[1]);
return $server['subscribe_url'] ?? null;
}
return null;
}
} }

View file

@ -2,15 +2,17 @@
namespace Friendica\Directory\Pollers; namespace Friendica\Directory\Pollers;
use Friendica\Directory\Utils\Network;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Directory class Directory
{ {
/** /**
* @var \Atlas\Pdo\Connection * @var \GuzzleHttp\ClientInterface
*/ */
private $atlas; private $http;
/** /**
* @var \Friendica\Directory\Models\ProfilePollQueue * @var \Friendica\Directory\Models\ProfilePollQueue
*/ */
@ -28,12 +30,12 @@ class Directory
]; ];
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas, \GuzzleHttp\ClientInterface $http,
\Friendica\Directory\Models\ProfilePollQueue $profilePollQueueModel, \Friendica\Directory\Models\ProfilePollQueue $profilePollQueueModel,
\Psr\Log\LoggerInterface $logger, \Psr\Log\LoggerInterface $logger,
array $settings) array $settings)
{ {
$this->atlas = $atlas; $this->http = $http;
$this->profilePollQueueModel = $profilePollQueueModel; $this->profilePollQueueModel = $profilePollQueueModel;
$this->logger = $logger; $this->logger = $logger;
$this->settings = array_merge($this->settings, $settings); $this->settings = array_merge($this->settings, $settings);
@ -80,35 +82,7 @@ class Directory
$path = '/sync/pull/since/' . $last_polled; $path = '/sync/pull/since/' . $last_polled;
} }
//Prepare the CURL call. $pull_data = $this->http->get($directory_url . $path, ['timeout' => max($this->settings['probe_timeout'], 1)])->getBody()->getContents();
$handle = curl_init();
$options = array(
//Timeouts
CURLOPT_TIMEOUT => max($this->settings['probe_timeout'], 1), //Minimum of 1 second timeout.
CURLOPT_CONNECTTIMEOUT => 1,
//Redirecting
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_MAXREDIRS => 8,
//SSL
CURLOPT_SSL_VERIFYPEER => true,
// CURLOPT_VERBOSE => true,
// CURLOPT_CERTINFO => true,
CURLOPT_SSL_VERIFYHOST => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS,
//Basic request
CURLOPT_USERAGENT => 'friendica-directory-probe-1.0',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_URL => $directory_url . $path
);
curl_setopt_array($handle, $options);
$this->logger->info('Pulling profiles from directory URL: ' . $directory_url . $path);
//Probe the site.
$pull_data = curl_exec($handle);
//Done with CURL now.
curl_close($handle);
$data = json_decode($pull_data, true); $data = json_decode($pull_data, true);

View file

@ -2,13 +2,18 @@
namespace Friendica\Directory\Pollers; namespace Friendica\Directory\Pollers;
use Friendica\Directory\Utils\Network; use Friendica\Directory\Models;
use Friendica\Directory\Utils;
use GuzzleHttp\Exception\RequestException;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Profile class Profile
{ {
const PROFILE_MISSING_CONFIRM = 2;
const PROFILE_MISSING_NOTIFY = 4;
const PROFILE_MISSING_POLL = 8;
/** /**
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
@ -16,12 +21,17 @@ class Profile
private $atlas; private $atlas;
/** /**
* @var \Friendica\Directory\Models\Server * @var \GuzzleHttp\ClientInterface
*/
private $http;
/**
* @var Models\Server
*/ */
private $serverModel; private $serverModel;
/** /**
* @var \Friendica\Directory\Models\Profile * @var Models\Profile
*/ */
private $profileModel; private $profileModel;
@ -40,13 +50,15 @@ class Profile
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas, \Atlas\Pdo\Connection $atlas,
\Friendica\Directory\Models\Server $serverModel, \GuzzleHttp\ClientInterface $http,
\Friendica\Directory\Models\Profile $profileModel, Models\Server $serverModel,
Models\Profile $profileModel,
\Psr\Log\LoggerInterface $logger, \Psr\Log\LoggerInterface $logger,
array $settings array $settings
) )
{ {
$this->atlas = $atlas; $this->atlas = $atlas;
$this->http = $http;
$this->serverModel = $serverModel; $this->serverModel = $serverModel;
$this->profileModel = $profileModel; $this->profileModel = $profileModel;
$this->logger = $logger; $this->logger = $logger;
@ -71,12 +83,12 @@ class Profile
return false; return false;
} }
if (!\Friendica\Directory\Utils\Network::isPublicHost($host)) { if (!Utils\Network::isPublicHost($host)) {
$this->logger->warning('Private/reserved IP in polled profile URL: ' . $profile_uri); $this->logger->warning('Private/reserved IP in polled profile URL: ' . $profile_uri);
return false; return false;
} }
$profileUriInfo = \Friendica\Directory\Models\Profile::extractInfoFromProfileUrl($profile_uri); $profileUriInfo = Models\Profile::extractInfoFromProfileUrl($profile_uri);
if (!$profileUriInfo) { if (!$profileUriInfo) {
$this->logger->warning('Profile URI invalid'); $this->logger->warning('Profile URI invalid');
return false; return false;
@ -119,29 +131,42 @@ class Profile
); );
} }
//Skip the profile scrape? $available = false;
$noscrape = $server['noscrape_url'];
$params = []; $params = [];
if ($noscrape) {
//Skip the profile scrape?
if ($server['noscrape_url']) {
$this->logger->debug('Calling ' . $server['noscrape_url'] . '/' . $username); $this->logger->debug('Calling ' . $server['noscrape_url'] . '/' . $username);
$params = \Friendica\Directory\Utils\Scrape::retrieveNoScrapeData($server['noscrape_url'] . '/' . $username); try {
$noscrape = !!$params; //If the result was false, do a scrape after all. $params = Utils\Scrape::retrieveNoScrapeData($this->http, $server['noscrape_url'] . '/' . $username);
} catch (RequestException $e) {
$this->logger->info('Request failed with error code ' . $e->getCode());
} catch (\Throwable $e) {
$this->logger->warning('Request failed with exception ' . get_class($e));
$this->logger->warning(var_export($e, true));
}
$available = !!$params; //If the result was false, do a scrape after all.
} }
$available = true; if (!$available) {
$this->logger->info('Parsing profile page ' . $profile_uri);
if ($noscrape) { try {
$available = Network::testURL($profile_uri); $params = Utils\Scrape::retrieveProfileData($this->http, $profile_uri);
$this->logger->debug('Testing ' . $profile_uri . ': ' . ($available?'Success':'Failure')); } catch (RequestException $e) {
} else { $this->logger->info('Request failed with error code ' . $e->getCode());
$this->logger->notice('Parsing profile page ' . $profile_uri); } catch (\Throwable $e) {
$params = \Friendica\Directory\Utils\Scrape::retrieveProfileData($profile_uri); $this->logger->warning('Request failed with exception ' . get_class($e));
$this->logger->warning(var_export($e, true));
}
$params['language'] = $server['language']; $params['language'] = $server['language'];
$available = !empty($params['fn']);
} }
// Empty result is due to an offline site. // Empty result is due to an offline site.
if (count($params) < 2) { if (empty($params) || count($params) < 2) {
//But for sites that are already in bad status. Do a cleanup now. //But for sites that are already in bad status. Do a cleanup now.
if ($profile_id && $server['health_score'] < $this->settings['remove_profile_health_threshold']) { if ($profile_id && $server['health_score'] < $this->settings['remove_profile_health_threshold']) {
$this->profileModel->deleteById($profile_id); $this->profileModel->deleteById($profile_id);
@ -171,14 +196,37 @@ class Profile
} }
// This is most likely a problem with the site configuration. Ignore. // This is most likely a problem with the site configuration. Ignore.
if (self::validateParams($params)) { if ($error = self::validateParams($params)) {
$this->logger->warning('Poll aborted, parameters invalid.', ['params' => $params]); $this->logger->warning('Poll aborted, parameters invalid.', ['params' => $params]);
if ($error & Profile::PROFILE_MISSING_CONFIRM) {
$this->logger->notice('dfrn-confirm parameter is empty.');
}
if ($error & Profile::PROFILE_MISSING_NOTIFY) {
$this->logger->notice('dfrn-notify parameter is empty.');
}
if ($error & Profile::PROFILE_MISSING_POLL) {
$this->logger->notice('dfrn-poll parameter is empty.');
}
return false; return false;
} }
$account_type = 'People'; switch ($params['account-type'] ?? Models\Profile::ACCOUNT_TYPE_PERSON) {
if (!empty($params['comm'])) { case Models\Profile::ACCOUNT_TYPE_ORGANISATION: $account_type = 'Organization'; break;
$account_type = 'Forum'; case Models\Profile::ACCOUNT_TYPE_NEWS : $account_type = 'News'; break;
case Models\Profile::ACCOUNT_TYPE_COMMUNITY : $account_type = 'Group'; break;
case Models\Profile::ACCOUNT_TYPE_RELAY : $account_type = 'Relay'; break;
case Models\Profile::ACCOUNT_TYPE_DELETED : $account_type = 'Deleted'; break;
case Models\Profile::ACCOUNT_TYPE_PERSON: {
$account_type = 'People';
if (!empty($params['comm'])) {
$account_type = 'Group';
}
break;
}
default: $account_type = 'Unknown'; break;
} }
$tags = []; $tags = [];
@ -208,7 +256,6 @@ class Profile
'region' => $params['region'] ?? '', 'region' => $params['region'] ?? '',
'country' => $params['country-name'] ?? '', 'country' => $params['country-name'] ?? '',
'profile_url' => $profile_uri, 'profile_url' => $profile_uri,
'dfrn_request' => $params['dfrn-request'] ?? null,
'photo' => $params['photo'], 'photo' => $params['photo'],
'tags' => implode(' ', $tags), 'tags' => implode(' ', $tags),
'addr' => $addr, 'addr' => $addr,
@ -216,7 +263,7 @@ class Profile
'language' => $params['language'] ?? null, 'language' => $params['language'] ?? null,
'filled_fields'=> $filled_fields, 'filled_fields'=> $filled_fields,
'last_activity'=> $params['last-activity'] ?? null, 'last_activity'=> $params['last-activity'] ?? null,
'available' => $available, 'available' => [$available, \PDO::PARAM_BOOL],
]; ];
$this->logger->debug(var_export($values, true)); $this->logger->debug(var_export($values, true));
@ -230,7 +277,6 @@ class Profile
`region` = :region, `region` = :region,
`country` = :country, `country` = :country,
`profile_url` = :profile_url, `profile_url` = :profile_url,
`dfrn_request` = :dfrn_request,
`photo` = :photo, `photo` = :photo,
`tags` = :tags, `tags` = :tags,
`addr` = :addr, `addr` = :addr,
@ -250,7 +296,6 @@ class Profile
`region` = :region, `region` = :region,
`country` = :country, `country` = :country,
`profile_url` = :profile_url, `profile_url` = :profile_url,
`dfrn_request` = :dfrn_request,
`photo` = :photo, `photo` = :photo,
`tags` = :tags, `tags` = :tags,
`addr` = :addr, `addr` = :addr,
@ -284,23 +329,27 @@ class Profile
$status = false; $status = false;
if ($profile_id) { if ($profile_id) {
$img_str = \Friendica\Directory\Utils\Network::fetchURL($params['photo'], true); try {
$img = new \Friendica\Directory\Utils\Photo($img_str); $img_str = $this->http->get($params['photo'])->getBody()->getContents();
if ($img->getImage()) { $img = new Utils\Photo($img_str);
$img->scaleImageSquare(80); if ($img->getImage()) {
$img->scaleImageSquare(80);
$this->atlas->perform('INSERT INTO `photo` SET $this->atlas->perform('INSERT INTO `photo` SET
`profile_id` = :profile_id, `profile_id` = :profile_id,
`data` = :data `data` = :data
ON DUPLICATE KEY UPDATE ON DUPLICATE KEY UPDATE
`data` = :data', `data` = :data',
[ [
'profile_id' => $profile_id, 'profile_id' => $profile_id,
'data' => $img->imageString() 'data' => $img->imageString()
] ]
); );
}
$status = true;
} catch (RequestException $e) {
$this->logger->info('Photo retrieval unsuccessful', ['url' => $params['photo'], 'code' => $e->getCode()]);
} }
$status = true;
} }
$submit_end = microtime(true); $submit_end = microtime(true);
@ -330,23 +379,21 @@ class Profile
return true; return true;
} }
/**
* @param array $params
* @return int
*/
private static function validateParams(array $params): int private static function validateParams(array $params): int
{ {
$errors = 0; $errors = 0;
if (empty($params['key'])) {
$errors++;
}
if (empty($params['dfrn-request'])) {
$errors++;
}
if (empty($params['dfrn-confirm'])) { if (empty($params['dfrn-confirm'])) {
$errors++; $errors &= self::PROFILE_MISSING_CONFIRM;
} }
if (empty($params['dfrn-notify'])) { if (empty($params['dfrn-notify'])) {
$errors++; $errors &= self::PROFILE_MISSING_NOTIFY;
} }
if (empty($params['dfrn-poll'])) { if (empty($params['dfrn-poll'])) {
$errors++; $errors &= self::PROFILE_MISSING_POLL;
} }
return $errors; return $errors;

View file

@ -2,8 +2,12 @@
namespace Friendica\Directory\Pollers; namespace Friendica\Directory\Pollers;
use GuzzleHttp\Psr7\Uri;
use GuzzleHttp\Exception\RequestException;
use GuzzleHttp\TransferStats;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Server class Server
{ {
@ -11,6 +15,10 @@ class Server
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
*/ */
private $atlas; private $atlas;
/**
* @var \GuzzleHttp\ClientInterface
*/
private $http;
/** /**
* @var \Friendica\Directory\Models\ProfilePollQueue * @var \Friendica\Directory\Models\ProfilePollQueue
*/ */
@ -38,6 +46,7 @@ class Server
public function __construct( public function __construct(
\Atlas\Pdo\Connection $atlas, \Atlas\Pdo\Connection $atlas,
\GuzzleHttp\ClientInterface $http,
\Friendica\Directory\Models\ProfilePollQueue $profilePollQueueModel, \Friendica\Directory\Models\ProfilePollQueue $profilePollQueueModel,
\Friendica\Directory\Models\Server $serverModel, \Friendica\Directory\Models\Server $serverModel,
\Psr\SimpleCache\CacheInterface $simplecache, \Psr\SimpleCache\CacheInterface $simplecache,
@ -45,6 +54,7 @@ class Server
array $settings) array $settings)
{ {
$this->atlas = $atlas; $this->atlas = $atlas;
$this->http = $http;
$this->profilePollQueueModel = $profilePollQueueModel; $this->profilePollQueueModel = $profilePollQueueModel;
$this->serverModel = $serverModel; $this->serverModel = $serverModel;
$this->simplecache = $simplecache; $this->simplecache = $simplecache;
@ -87,6 +97,8 @@ class Server
$parse_success = !empty($probe_result['data']['url']); $parse_success = !empty($probe_result['data']['url']);
$avg_ping = null;
if ($parse_success) { if ($parse_success) {
$base_url = $probe_result['data']['url']; $base_url = $probe_result['data']['url'];
@ -142,6 +154,10 @@ class Server
$addons = $probe_result['data']['plugins']; $addons = $probe_result['data']['plugins'];
} }
if (!empty($probe_result['data']['admin']['profile'])) {
$subscribe = $this->getSubscribeUrl($probe_result['data']['url'], $probe_result['data']['admin']['profile']);
}
$this->atlas->perform( $this->atlas->perform(
'UPDATE `server` 'UPDATE `server`
SET `available` = 1, SET `available` = 1,
@ -156,20 +172,22 @@ class Server
`admin_name` = :admin_name, `admin_name` = :admin_name,
`admin_profile` = :admin_profile, `admin_profile` = :admin_profile,
`noscrape_url` = :noscrape_url, `noscrape_url` = :noscrape_url,
`subscribe_url` = :subscribe_url,
`ssl_state` = :ssl_state `ssl_state` = :ssl_state
WHERE `id` = :server_id', WHERE `id` = :server_id',
[ [
'server_id' => $server['id'], 'server_id' => $server['id'],
'base_url' => strtolower($probe_result['data']['url']), 'base_url' => strtolower($probe_result['data']['url']),
'name' => $probe_result['data']['site_name'], 'name' => substr($probe_result['data']['site_name'], 0, 255),
'language' => $probe_result['data']['language'] ?? null, 'language' => $probe_result['data']['language'] ?? null,
'version' => $probe_result['data']['version'], 'version' => $probe_result['data']['version'],
'addons' => implode(',', $addons), 'addons' => implode(',', $addons),
'reg_policy' => $probe_result['data']['register_policy'], 'reg_policy' => $probe_result['data']['register_policy'],
'info' => $probe_result['data']['info'], 'info' => $probe_result['data']['info'],
'admin_name' => $probe_result['data']['admin']['name'], 'admin_name' => $probe_result['data']['admin']['name'] ?? null,
'admin_profile' => $probe_result['data']['admin']['profile'], 'admin_profile' => $probe_result['data']['admin']['profile'] ?? null,
'noscrape_url' => $probe_result['data']['no_scrape_url'] ?? null, 'noscrape_url' => $probe_result['data']['no_scrape_url'] ?? null,
'subscribe_url' => $subscribe ?? null,
'ssl_state' => $probe_result['ssl_state'] 'ssl_state' => $probe_result['ssl_state']
] ]
); );
@ -179,12 +197,24 @@ class Server
$result = $this->profilePollQueueModel->add($probe_result['data']['admin']['profile']); $result = $this->profilePollQueueModel->add($probe_result['data']['admin']['profile']);
$this->logger->debug('Profile queue add URL: ' . $probe_result['data']['admin']['profile'] . ' - ' . $result); $this->logger->debug('Profile queue add URL: ' . $probe_result['data']['admin']['profile'] . ' - ' . $result);
} }
$this->discoverPoco($base_url);
} else {
$this->logger->debug('Parse unsuccessful', ['$polled_url' => $polled_url, '$probe_result' => $probe_result]);
} }
if ($server) { if ($server) {
//Get the new health. //Get the new health.
$version = $parse_success ? $probe_result['data']['version'] : ''; $version = $parse_success ? $probe_result['data']['version'] : '';
$health_score = $this->computeHealthScore($server['health_score'], $parse_success, $probe_result['time'], $version, $probe_result['ssl_state']); $health_score = $this->computeHealthScore(
$server['health_score'],
$parse_success,
$probe_result['time'],
$version,
$probe_result['ssl_state'],
$avg_ping,
$probe_result['data']['info'] ?? null
);
$this->atlas->perform( $this->atlas->perform(
'UPDATE `server` SET `health_score` = :health_score WHERE `id` = :server_id', 'UPDATE `server` SET `health_score` = :health_score WHERE `id` = :server_id',
@ -224,65 +254,50 @@ class Server
private function getProbeResult(string $base_url): array private function getProbeResult(string $base_url): array
{ {
//Prepare the CURL call. $curl_info = null;
$handle = curl_init();
$options = array( $options = [
//Timeouts 'timeout' => max($this->settings['probe_timeout'], 1),
CURLOPT_TIMEOUT => max($this->settings['probe_timeout'], 1), //Minimum of 1 second timeout. 'on_stats' => function (TransferStats $transferStats) use (&$curl_info) {
CURLOPT_CONNECTTIMEOUT => 1, $curl_info = $transferStats->getHandlerStats();
//Redirecting }
CURLOPT_FOLLOWLOCATION => true, ];
CURLOPT_MAXREDIRS => 8,
//SSL $sslcert_issues = false;
CURLOPT_SSL_VERIFYPEER => true,
// CURLOPT_VERBOSE => true,
// CURLOPT_CERTINFO => true,
CURLOPT_SSL_VERIFYHOST => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS,
//Basic request
CURLOPT_USERAGENT => 'friendica-directory-probe-1.0',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_URL => $base_url . '/friendica/json'
);
curl_setopt_array($handle, $options);
//Probe the site.
$probe_start = microtime(true); $probe_start = microtime(true);
$probe_data = curl_exec($handle); $probe_data = null;
$probe_end = microtime(true); try {
//Probe the site.
$probe_data = $this->http->get($base_url . '/friendica/json', $options)->getBody()->getContents();
} catch (RequestException $e) {
if (in_array($e->getHandlerContext()['errno'] ?? 0, [
60, //Could not authenticate certificate with known CA's
83 //Issuer check failed
])) {
$sslcert_issues = true;
//Check for SSL problems. //When it's the certificate that doesn't work, we probe again without strict SSL.
$curl_statuscode = curl_errno($handle); $options['verify'] = false;
$sslcert_issues = in_array($curl_statuscode, array(
60, //Could not authenticate certificate with known CA's
83 //Issuer check failed
));
//When it's the certificate that doesn't work. $probe_start = microtime(true);
if ($sslcert_issues) { try {
//Probe again, without strict SSL. $probe_data = $this->http->get($base_url . '/friendica/json', $options)->getBody()->getContents();
$options[CURLOPT_SSL_VERIFYPEER] = false; } catch(RequestException $e) {
// Collects 404, 500 errors
//Replace the handle. $this->logger->info('SSL-non-verified URL probe failed with error code: ' . $e->getCode());
curl_close($handle); }
$handle = curl_init(); } else {
curl_setopt_array($handle, $options); $this->logger->info('SSL-verified URL probe failed with error code: ' . $e->getCode());
}
//Probe. } catch (\InvalidArgumentException $e) {
$probe_start = microtime(true); $this->logger->error('Invalid argument provided to HTTP client', ['base_url' => $base_url, 'exception' => $e]);
$probe_data = curl_exec($handle); return ['data' => false, 'time' => 0, 'curl_info' => [], 'ssl_state' => null];
$probe_end = microtime(true);
//Store new status.
$curl_statuscode = curl_errno($handle);
} }
//Gather more meta. $probe_end = microtime(true);
$time = round(($probe_end - $probe_start) * 1000);
$curl_info = curl_getinfo($handle);
//Done with CURL now. $time = round(($probe_end - $probe_start) * 1000);
curl_close($handle);
try { try {
$data = json_decode($probe_data, true); $data = json_decode($probe_data, true);
@ -302,7 +317,15 @@ class Server
return ['data' => $data, 'time' => $time, 'curl_info' => $curl_info, 'ssl_state' => $ssl_state]; return ['data' => $data, 'time' => $time, 'curl_info' => $curl_info, 'ssl_state' => $ssl_state];
} }
private function computeHealthScore(int $original_health, bool $probe_success, int $time = null, string $version = null, int $ssl_state = null): int private function computeHealthScore(
int $original_health,
bool $probe_success,
?int $time,
?string $version,
?int $ssl_state,
?float $avg_ping,
?string $description
): int
{ {
//Probe failed, costs you 30 points. //Probe failed, costs you 30 points.
if (!$probe_success) { if (!$probe_success) {
@ -351,7 +374,7 @@ class Server
} else { } else {
$stable_version = $this->simplecache->get('stable_version'); $stable_version = $this->simplecache->get('stable_version');
if (!$stable_version) { if (!$stable_version) {
$stable_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/master/VERSION')); $stable_version = trim(file_get_contents('https://git.friendi.ca/friendica/friendica/raw/branch/stable/VERSION'));
$this->simplecache->set('stable_version', $stable_version); $this->simplecache->set('stable_version', $stable_version);
} }
@ -361,14 +384,108 @@ class Server
$this->simplecache->set('dev_version', $dev_version); $this->simplecache->set('dev_version', $dev_version);
} }
if ($version == $dev_version) { $rc_version = str_replace('-dev', '-rc', $dev_version);
$max_health = 95; //Develop can be unstable
if ($version == $dev_version || $version == $rc_version) {
$old_max_health = $max_health;
$new_max_health = 95; //Develop/RC can be unstable
$max_health = min($old_max_health, $new_max_health);
} elseif ($version !== $stable_version) { } elseif ($version !== $stable_version) {
$delta = min($delta, 0) - 10; // Losing score as time passes if node isn't updated $delta = min($delta, 0) - 10; // Losing score as time passes if node isn't updated
} }
} }
} }
// No description available penalty
if (!$description) {
$max_health = min(75, $max_health);
}
// No ping penalty
if (!$avg_ping) {
$max_health -= 5;
}
return max(min($max_health, $original_health + $delta), -100); return max(min($max_health, $original_health + $delta), -100);
} }
function discoverPoco($base_url): void
{
$uri = Uri::withQueryValues(new Uri($base_url . '/poco'), ['fields' => 'urls', 'count' => 1000]);
try {
$response = $this->http->request('GET', $uri);
} catch (RequestException $e) {
$this->logger->info('Unsuccessful poco request: ' . $uri);
return;
}
try {
$pocoFetchData = json_decode($response->getBody()->getContents());
} catch (\Throwable $e) {
$this->logger->notice('Invalid JSON string for PoCo URL: ' . $uri);
return;
}
if (!isset($pocoFetchData->entry)) {
$this->logger->notice('Invalid JSON structure for PoCo URL: ' . $uri);
return;
}
foreach($pocoFetchData->entry as $entry) {
if (empty($entry->urls)) {
continue;
}
foreach ($entry->urls as $url) {
if (!empty($url->type) && !empty($url->value) && $url->type == 'profile') {
$result = $this->profilePollQueueModel->add($url->value);
if ($result === 0) {
$this->logger->info('Discovered profile URL ' . $url->value);
}
}
}
}
}
public function getSubscribeUrl($base_url, $profile)
{
$uri = Uri::withQueryValues(new Uri($base_url . '/xrd'), ['uri' => $profile]);
try {
$response = $this->http->request('GET', $uri, ['headers' => ['Accept' => 'application/jrd+json']]);
} catch (RequestException $e) {
$this->logger->info('Unsuccessful xrd request: ' . $uri);
return null;
}
$xrdJsonData = $response->getBody()->getContents();
$this->logger->debug('WebRequest: ' . $uri . ' Status: ' . $response->getStatusCode());
if ($response->getStatusCode() != 200) {
$this->logger->info('Unsuccessful XRD request: ' . $uri);
return null;
}
try {
$xrdData = json_decode($xrdJsonData);
} catch (\Throwable $e) {
$this->logger->notice('Invalid JSON string for XRD URL: ' . $uri);
return null;
}
if (!isset($xrdData->links)) {
$this->logger->notice('Invalid JSON structure for XRD URL: ' . $uri);
return null;
}
foreach ($xrdData->links as $link) {
if ($link->rel == 'http://ostatus.org/schema/1.0/subscribe') {
return $link->template ?? null;
}
}
return null;
}
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
abstract class BaseRoute abstract class BaseRoute
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class DirectoryAdd extends BaseRoute class DirectoryAdd extends BaseRoute
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class DirectoryPoll extends BaseRoute class DirectoryPoll extends BaseRoute
{ {
@ -11,7 +11,7 @@ class DirectoryPoll extends BaseRoute
{ {
return (new \Friendica\Directory\Controllers\Console\DirectoryPoll( return (new \Friendica\Directory\Controllers\Console\DirectoryPoll(
$this->container->get('atlas'), $this->container->get('atlas'),
$this->container->get('\Friendica\Directory\Pollers\Directory'), $this->container->get(\Friendica\Directory\Pollers\Directory::class),
$args $args
)); ));
} }

View file

@ -3,14 +3,14 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ExtractStrings extends BaseRoute class ExtractStrings extends BaseRoute
{ {
public function __invoke(array $args) public function __invoke(array $args)
{ {
return (new \Friendica\Directory\Controllers\Console\ExtractStrings( return (new \Friendica\Directory\Controllers\Console\ExtractStrings(
$this->container->get('settings')['i18n']['locales'], $this->container->get('settings')['i18n']['path'],
$args $args
)); ));
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Install extends BaseRoute class Install extends BaseRoute
{ {

View file

@ -3,14 +3,14 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfileAdd extends BaseRoute class ProfileAdd extends BaseRoute
{ {
public function __invoke(array $args) public function __invoke(array $args)
{ {
return (new \Friendica\Directory\Controllers\Console\ProfileAdd( return (new \Friendica\Directory\Controllers\Console\ProfileAdd(
$this->container->get('\Friendica\Directory\Models\ProfilePollQueue'), $this->container->get(\Friendica\Directory\Models\ProfilePollQueue::class),
$args $args
)); ));
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfileHide extends BaseRoute class ProfileHide extends BaseRoute
{ {

View file

@ -3,14 +3,14 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ProfilePoll extends BaseRoute class ProfilePoll extends BaseRoute
{ {
public function __invoke(array $args) public function __invoke(array $args)
{ {
return (new \Friendica\Directory\Controllers\Console\ProfilePoll( return (new \Friendica\Directory\Controllers\Console\ProfilePoll(
$this->container->get('\Friendica\Directory\Pollers\Profile'), $this->container->get(\Friendica\Directory\Pollers\Profile::class),
$args $args
)); ));
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ServerHide extends BaseRoute class ServerHide extends BaseRoute
{ {
@ -11,7 +11,7 @@ class ServerHide extends BaseRoute
{ {
return (new \Friendica\Directory\Controllers\Console\ServerHide( return (new \Friendica\Directory\Controllers\Console\ServerHide(
$this->container->get('atlas'), $this->container->get('atlas'),
$this->container->get('\Friendica\Directory\Models\Server'), $this->container->get(\Friendica\Directory\Models\Server::class),
$args $args
)); ));
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class ServerPoll extends BaseRoute class ServerPoll extends BaseRoute
{ {
@ -11,7 +11,7 @@ class ServerPoll extends BaseRoute
{ {
return (new \Friendica\Directory\Controllers\Console\ServerPoll( return (new \Friendica\Directory\Controllers\Console\ServerPoll(
$this->container->get('atlas'), $this->container->get('atlas'),
$this->container->get('\Friendica\Directory\Pollers\Server'), $this->container->get(\Friendica\Directory\Pollers\Server::class),
$args $args
)); ));
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Console; namespace Friendica\Directory\Routes\Console;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class UpdateDb extends BaseRoute class UpdateDb extends BaseRoute
{ {

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Http; namespace Friendica\Directory\Routes\Http;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
abstract class BaseRoute abstract class BaseRoute
{ {

View file

@ -0,0 +1,17 @@
<?php
namespace Friendica\Directory\Routes\Http;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class MatchSearch extends BaseRoute
{
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{
return (new \Friendica\Directory\Controllers\Api\MatchSearch(
$this->container->get(\Friendica\Directory\Models\Profile::class),
$this->container->l10n
))->render($request, $response, $args);
}
}

View file

@ -3,14 +3,15 @@
namespace Friendica\Directory\Routes\Http; namespace Friendica\Directory\Routes\Http;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Photo extends BaseRoute class Photo extends BaseRoute
{ {
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{ {
return (new \Friendica\Directory\Controllers\Api\Photo( return (new \Friendica\Directory\Controllers\Api\Photo(
$this->container->atlas $this->container->atlas,
$this->container->get('defaultProfilePictureSmallPath')
))->render($request, $response, $args); ))->render($request, $response, $args);
} }
} }

View file

@ -3,15 +3,14 @@
namespace Friendica\Directory\Routes\Http; namespace Friendica\Directory\Routes\Http;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Search extends BaseRoute class Search extends BaseRoute
{ {
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{ {
return (new \Friendica\Directory\Controllers\Api\Search( return (new \Friendica\Directory\Controllers\Api\Search(
$this->container->atlas, $this->container->get(\Friendica\Directory\Models\Profile::class),
$this->container->get('\Friendica\Directory\Models\Profile'),
$this->container->l10n $this->container->l10n
))->render($request, $response, $args); ))->render($request, $response, $args);
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Http; namespace Friendica\Directory\Routes\Http;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Submit extends BaseRoute class Submit extends BaseRoute
{ {
@ -11,7 +11,7 @@ class Submit extends BaseRoute
{ {
return (new \Friendica\Directory\Controllers\Api\Submit( return (new \Friendica\Directory\Controllers\Api\Submit(
$this->container->atlas, $this->container->atlas,
$this->container->get('\Friendica\Directory\Models\ProfilePollQueue'), $this->container->get(\Friendica\Directory\Models\ProfilePollQueue::class),
$this->container->logger $this->container->logger
))->execute($request, $response); ))->execute($request, $response);
} }

View file

@ -0,0 +1,16 @@
<?php
namespace Friendica\Directory\Routes\Http;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Surprise extends BaseRoute
{
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{
return (new \Friendica\Directory\Controllers\Api\Surprise(
$this->container->atlas
))->render($request, $response, $args);
}
}

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Http; namespace Friendica\Directory\Routes\Http;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class SyncPull extends BaseRoute class SyncPull extends BaseRoute
{ {

View file

@ -5,7 +5,7 @@ namespace Friendica\Directory\Routes\Web;
use Friendica\Directory\Controllers\Web\BaseController; use Friendica\Directory\Controllers\Web\BaseController;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
abstract class BaseRoute abstract class BaseRoute
{ {
@ -27,6 +27,8 @@ abstract class BaseRoute
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, array $args): \Slim\Http\Response
{ {
$defaults = [ $defaults = [
'pages' => glob(__DIR__ . '/../../../../config/pages/*.html'),
'version' => file_get_contents(__DIR__ . '/../../../../VERSION'),
'languages' => $this->container->settings['i18n']['locales'], 'languages' => $this->container->settings['i18n']['locales'],
'lang' => $request->getAttribute('locale'), 'lang' => $request->getAttribute('locale'),
'baseUrl' => $request->getUri()->getBaseUrl(), 'baseUrl' => $request->getUri()->getBaseUrl(),

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Web; namespace Friendica\Directory\Routes\Web;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Directory extends BaseRoute class Directory extends BaseRoute
{ {
@ -13,8 +13,9 @@ class Directory extends BaseRoute
$this->controller = new \Friendica\Directory\Controllers\Web\Directory( $this->controller = new \Friendica\Directory\Controllers\Web\Directory(
$this->container->atlas, $this->container->atlas,
$this->container->get('\Friendica\Directory\Models\Profile'), $this->container->get(\Friendica\Directory\Models\Server::class),
$this->container->get('\Friendica\Directory\Views\Widget\AccountTypeTabs'), $this->container->get(\Friendica\Directory\Models\Profile::class),
$this->container->get(\Friendica\Directory\Views\Widget\AccountTypeTabs::class),
$this->container->renderer, $this->container->renderer,
$this->container->l10n $this->container->l10n
); );

View file

@ -0,0 +1,18 @@
<?php
namespace Friendica\Directory\Routes\Web;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Pages extends BaseRoute
{
public function __construct(\Slim\Container $container, $pageFile)
{
parent::__construct($container);
$this->controller = new \Friendica\Directory\Controllers\Web\Page(
$pageFile
);
}
}

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Web; namespace Friendica\Directory\Routes\Web;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Search extends BaseRoute class Search extends BaseRoute
{ {
@ -13,8 +13,9 @@ class Search extends BaseRoute
$this->controller = new \Friendica\Directory\Controllers\Web\Search( $this->controller = new \Friendica\Directory\Controllers\Web\Search(
$this->container->atlas, $this->container->atlas,
$this->container->get('\Friendica\Directory\Models\Profile'), $this->container->get(\Friendica\Directory\Models\Server::class),
$this->container->get('\Friendica\Directory\Views\Widget\AccountTypeTabs'), $this->container->get(\Friendica\Directory\Models\Profile::class),
$this->container->get(\Friendica\Directory\Views\Widget\AccountTypeTabs::class),
$this->container->renderer, $this->container->renderer,
$this->container->l10n $this->container->l10n
); );

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Routes\Web; namespace Friendica\Directory\Routes\Web;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Servers extends BaseRoute class Servers extends BaseRoute
{ {

View file

@ -0,0 +1,20 @@
<?php
namespace Friendica\Directory\Routes\Web;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Statistics extends BaseRoute
{
public function __construct(\Slim\Container $container)
{
parent::__construct($container);
$this->controller = new \Friendica\Directory\Controllers\Web\Statistics(
$this->container->atlas,
$this->container->simplecache,
$this->container->renderer
);
}
}

View file

@ -6,10 +6,13 @@ use Gettext\Languages\Language;
use Gettext\Translator; use Gettext\Translator;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class L10n class L10n
{ {
const DECIMAL = 1;
const PERCENT = 2;
public static $languages = [ public static $languages = [
'af' => 'Afrikaans', 'af' => 'Afrikaans',
'ak' => 'Akan', 'ak' => 'Akan',
@ -80,6 +83,7 @@ class L10n
'ks' => 'کٲشُر', 'ks' => 'کٲشُر',
'kw' => 'Kernewek', 'kw' => 'Kernewek',
'ky' => 'Кыргызча', 'ky' => 'Кыргызча',
'la' => 'Lingua Latina',
'lb' => 'Lëtzebuergesch', 'lb' => 'Lëtzebuergesch',
'lg' => 'Luganda', 'lg' => 'Luganda',
'ln' => 'Lingála', 'ln' => 'Lingála',
@ -150,16 +154,62 @@ class L10n
'zu' => 'Isizulu', 'zu' => 'Isizulu',
]; ];
public static function langToString($lang) public static function localeToLanguageString($locale)
{ {
$found = false; $lang = substr($locale, 0, 2);
$foundLocale = false;
$foundLang = false;
foreach(self::$languages as $key => $language) { foreach(self::$languages as $key => $language) {
if (strtolower($key) == strtolower(str_replace('-', '_', $lang))) { if (strtolower($key) == strtolower($lang)) {
$found = true; $foundLang = $language;
}
if (strtolower($key) == strtolower(str_replace('-', '_', $locale))) {
$foundLocale = $language;
break; break;
} }
} }
return $found ? $language : $lang; return $foundLocale ?: $foundLang ?: $locale;
}
/**
* @param float|int $number
* @param int $style
* @return string
*/
public static function formatNumber($number, $style = self::DECIMAL)
{
$locale = localeconv();
switch($style) {
case self::PERCENT:
$number *= 100;
if (\intval($number) == $number) {
$decimals = 0;
} else {
$decimals = 2;
}
$return = number_format($number, $decimals,
$locale['decimal_point'],
$locale['thousands_sep']) . '%';
break;
case self::DECIMAL:
default:
if (\intval($number) == $number) {
$decimals = 0;
} else {
$decimals = 2;
}
$return = number_format($number, $decimals,
$locale['decimal_point'],
$locale['thousands_sep']);
break;
}
return $return;
} }
} }

View file

@ -11,56 +11,10 @@ namespace Friendica\Directory\Utils;
/** /**
* Description of Network * Description of Network
* *
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Network class Network
{ {
public static function fetchURL(string $url, bool $binary = false, int $timeout = 20): string
{
$ch = curl_init($url);
if (!$ch) {
return false;
}
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_TIMEOUT, max($timeout, 1)); //Minimum of 1 second timeout.
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 8);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
if ($binary) {
curl_setopt($ch, CURLOPT_BINARYTRANSFER, 1);
}
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
$s = curl_exec($ch);
curl_close($ch);
return $s;
}
public static function testURL(string $url, int $timeout = 20): bool
{
$ch = curl_init($url);
if (!$ch) {
return false;
}
curl_setopt($ch, CURLOPT_HEADER , 0);
curl_setopt($ch, CURLOPT_TIMEOUT , max($timeout, 1)); //Minimum of 1 second timeout.
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_MAXREDIRS , 8);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);
curl_setopt($ch, CURLOPT_NOBODY , true);
curl_exec($ch);
$responseCode = intval(curl_getinfo($ch, CURLINFO_RESPONSE_CODE));
$testSuccess = curl_errno($ch) === 0 && $responseCode < 400;
curl_close($ch);
return $testSuccess;
}
/** /**
* Check if a hostname is public and non-reserved * Check if a hostname is public and non-reserved
* *

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Utils; namespace Friendica\Directory\Utils;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Photo class Photo
{ {

View file

@ -2,8 +2,10 @@
namespace Friendica\Directory\Utils; namespace Friendica\Directory\Utils;
use GuzzleHttp\ClientInterface;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class Scrape class Scrape
{ {
@ -12,10 +14,10 @@ class Scrape
* @param string $url * @param string $url
* @return array|false * @return array|false
*/ */
public static function retrieveNoScrapeData(string $url) public static function retrieveNoScrapeData(ClientInterface $http, string $url)
{ {
$submit_noscrape_start = microtime(true); $submit_noscrape_start = microtime(true);
$data = Network::fetchURL($url); $data = $http->get($url)->getBody()->getContents();
$submit_noscrape_request_end = microtime(true); $submit_noscrape_request_end = microtime(true);
if (empty($data)) { if (empty($data)) {
@ -23,7 +25,7 @@ class Scrape
} }
$params = json_decode($data, true); $params = json_decode($data, true);
if (!$params || !count($params)) { if (empty($params) || !is_array($params)) {
return false; return false;
} }
@ -42,7 +44,7 @@ class Scrape
return $params; return $params;
} }
public static function retrieveProfileData(string $url, int $max_nodes = 3500): array public static function retrieveProfileData(ClientInterface $http, string $url, int $max_nodes = 3500): array
{ {
$minNodes = 100; //Lets do at least 100 nodes per type. $minNodes = 100; //Lets do at least 100 nodes per type.
@ -56,7 +58,7 @@ class Scrape
$scrape_start = microtime(true); $scrape_start = microtime(true);
$params = []; $params = [];
$html = Network::fetchURL($url, false, $timeout); $html = $http->get($url, ['timeout' => $timeout])->getBody()->getContents();;
$scrape_fetch_end = microtime(true); $scrape_fetch_end = microtime(true);
@ -129,7 +131,7 @@ class Scrape
$nodes_left = max(intval($max_nodes), $minNodes); $nodes_left = max(intval($max_nodes), $minNodes);
$items = $dom->getElementsByTagName('*'); $items = $dom->getElementsByTagName('*');
$targets = array('fn', 'pdesc', 'photo', 'key', 'locality', 'region', 'postal-code', 'country-name'); $targets = array('fn', 'pdesc', 'photo', 'locality', 'region', 'postal-code', 'country-name');
$targets_left = count($targets); $targets_left = count($targets);
foreach ($items as $item) { foreach ($items as $item) {
if (self::attributeContains($item->getAttribute('class'), 'vcard')) { if (self::attributeContains($item->getAttribute('class'), 'vcard')) {
@ -147,10 +149,6 @@ class Scrape
$params['photo'] = $vcard_element->getAttribute('src'); $params['photo'] = $vcard_element->getAttribute('src');
$targets_left = self::popScrapeTarget($targets, 'photo'); $targets_left = self::popScrapeTarget($targets, 'photo');
} }
if (self::attributeContains($vcard_element->getAttribute('class'), 'key')) {
$params['key'] = $vcard_element->textContent;
$targets_left = self::popScrapeTarget($targets, 'key');
}
if (self::attributeContains($vcard_element->getAttribute('class'), 'locality')) { if (self::attributeContains($vcard_element->getAttribute('class'), 'locality')) {
$params['locality'] = $vcard_element->textContent; $params['locality'] = $vcard_element->textContent;
$targets_left = self::popScrapeTarget($targets, 'locality'); $targets_left = self::popScrapeTarget($targets, 'locality');

View file

@ -2,10 +2,12 @@
namespace Friendica\Directory\Views; namespace Friendica\Directory\Views;
use Slim\Router;
/** /**
* Zend-Escaper wrapper for Slim PHP Renderer * Zend-Escaper wrapper for Slim PHP Renderer
* *
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
* *
* @method string escapeHtml(string $value) * @method string escapeHtml(string $value)
* @method string escapeHtmlAttr(string $value) * @method string escapeHtmlAttr(string $value)
@ -32,10 +34,15 @@ class PhpRenderer extends \Slim\Views\PhpRenderer
* @var \Gettext\TranslatorInterface * @var \Gettext\TranslatorInterface
*/ */
private $l10n; private $l10n;
/**
* @var Router
*/
private $router;
public function __construct( public function __construct(
\Zend\Escaper\Escaper $escaper, \Zend\Escaper\Escaper $escaper,
\Gettext\TranslatorInterface $l10n, \Gettext\TranslatorInterface $l10n,
Router $router,
string $templatePath = "", string $templatePath = "",
array $attributes = array() array $attributes = array()
) )
@ -44,6 +51,7 @@ class PhpRenderer extends \Slim\Views\PhpRenderer
$this->escaper = $escaper; $this->escaper = $escaper;
$this->l10n = $l10n; $this->l10n = $l10n;
$this->router = $router;
} }
public function e(string $value): string public function e(string $value): string
@ -58,7 +66,7 @@ class PhpRenderer extends \Slim\Views\PhpRenderer
} elseif (method_exists($this->l10n, $name)) { } elseif (method_exists($this->l10n, $name)) {
return $this->l10n->$name(...$arguments); return $this->l10n->$name(...$arguments);
} else { } else {
throw new \Exception('Unknown PhpRendere magic method: ' . $name); throw new \Exception('Unknown PhpRenderer magic method: ' . $name);
} }
} }
@ -172,5 +180,36 @@ class PhpRenderer extends \Slim\Views\PhpRenderer
return !empty($args[1]) && is_array($args[1]) ? strtr($text, $args[1]) : vsprintf($text, $args); return !empty($args[1]) && is_array($args[1]) ? strtr($text, $args[1]) : vsprintf($text, $args);
} }
/**
* Return the URL of the provided route and parameters
*
* @param string $name
* @param array $data
* @param array $queryParams
* @return string
*/
function r(string $name, array $data = [], array $queryParams = [])
{
if ($this->getAttribute('zrl')) {
$queryParams['zrl'] = $this->getAttribute('zrl');
}
return $this->router->pathFor($name, $data, $queryParams);
}
/**
* Add sitewide ZRL support for external URLs
*
* @param string $url
*/
function u(string $url)
{
if ($this->getAttribute('zrl')) {
$uri = new \ByJG\Util\Uri($url);
$uri->withQueryKeyValue('zrl', $this->getAttribute('zrl'), false);
$url = $uri->__toString();
}
return $url;
}
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Views\Widget; namespace Friendica\Directory\Views\Widget;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class AccountTypeTabs class AccountTypeTabs
{ {
@ -40,7 +40,7 @@ class AccountTypeTabs
AND NOT p.`hidden` AND NOT p.`hidden`
' . $condition . ' ' . $condition . '
GROUP BY p.`account_type` GROUP BY p.`account_type`
ORDER BY `filled_fields` DESC, `last_activity` DESC, `updated` DESC'; ORDER BY `count` DESC';
$account_types = $this->connection->fetchAll($stmt, $values); $account_types = $this->connection->fetchAll($stmt, $values);
$tabs = [ $tabs = [
@ -53,8 +53,12 @@ class AccountTypeTabs
foreach ($account_types as $account_type) { foreach ($account_types as $account_type) {
switch ($account_type['account_type']) { switch ($account_type['account_type']) {
case 'People': $title = $this->renderer->np__('account-type', 'People (%d)', 'People (%d)', $account_type['count']); break; case 'People' : $title = $this->renderer->np__('account-type', 'People (%d)' , 'People (%d)' , $account_type['count']); break;
case 'Forum' : $title = $this->renderer->np__('account-type', 'Forum (%d)', 'Forums (%d)', $account_type['count']); break; case 'News' : $title = $this->renderer->np__('account-type', 'News (%d)' , 'News (%d)' , $account_type['count']); break;
case 'Organization': $title = $this->renderer->np__('account-type', 'Organization (%d)', 'Organizations (%d)', $account_type['count']); break;
// Kept for backward compatibility
case 'Forum' :
case 'Group' : $title = $this->renderer->np__('account-type', 'Group (%d)' , 'Groups (%d)' , $account_type['count']); break;
default: $title = $this->renderer->np__('account-type', $account_type['account_type']. ' (%d)', $account_type['account_type']. ' (%d)', $account_type['count']); default: $title = $this->renderer->np__('account-type', $account_type['account_type']. ' (%d)', $account_type['account_type']. ' (%d)', $account_type['count']);
} }

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Views\Widget; namespace Friendica\Directory\Views\Widget;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class PopularCountries class PopularCountries
{ {
@ -30,7 +30,7 @@ FROM `profile`
WHERE `country` != "" WHERE `country` != ""
AND `available` AND `available`
GROUP BY `country` GROUP BY `country`
ORDER BY COUNT(`country`) DESC ORDER BY `total` DESC
LIMIT 10'; LIMIT 10';
$countries = $this->connection->fetchAll($stmt); $countries = $this->connection->fetchAll($stmt);

View file

@ -3,9 +3,9 @@
namespace Friendica\Directory\Views\Widget; namespace Friendica\Directory\Views\Widget;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class PopularLanguages class PopularProfileLanguages
{ {
/** /**
* @var \Atlas\Pdo\Connection * @var \Atlas\Pdo\Connection
@ -24,13 +24,18 @@ class PopularLanguages
public function render(): string public function render(): string
{ {
$stmt = 'SELECT LEFT(`language`, 2) AS `language`, COUNT(*) AS `total` FROM `profile` WHERE `language` IS NOT NULL GROUP BY LEFT(`language`, 2) ORDER BY COUNT(*) DESC LIMIT 10'; $stmt = 'SELECT LEFT(`language`, 2) AS `language`, COUNT(*) AS `total`
FROM `profile`
WHERE `language` IS NOT NULL
GROUP BY LEFT(`language`, 2)
ORDER BY `total` DESC
LIMIT 10';
$languages = $this->connection->fetchAll($stmt); $languages = $this->connection->fetchAll($stmt);
$vars = [ $vars = [
'languages' => $languages 'languages' => $languages
]; ];
return $this->renderer->fetch('widget/popularlanguages.phtml', $vars); return $this->renderer->fetch('widget/popularprofilelanguages.phtml', $vars);
} }
} }

View file

@ -0,0 +1,44 @@
<?php
namespace Friendica\Directory\Views\Widget;
/**
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class PopularServerLanguages
{
/**
* @var \Atlas\Pdo\Connection
*/
private $connection;
/**
* @var \Friendica\Directory\Views\PhpRenderer
*/
private $renderer;
public function __construct(\Atlas\Pdo\Connection $connection, \Friendica\Directory\Views\PhpRenderer $renderer)
{
$this->connection = $connection;
$this->renderer = $renderer;
}
public function render(): string
{
$stmt = 'SELECT LEFT(`language`, 2) AS `language`, COUNT(*) AS `total`
FROM `server`
WHERE `reg_policy` != "REGISTER_CLOSED"
AND `available`
AND NOT `hidden`
AND `language` IS NOT NULL
GROUP BY LEFT(`language`, 2)
ORDER BY `total` DESC
LIMIT 10';
$languages = $this->connection->fetchAll($stmt);
$vars = [
'languages' => $languages
];
return $this->renderer->fetch('widget/popularserverlanguages.phtml', $vars);
}
}

View file

@ -3,7 +3,7 @@
namespace Friendica\Directory\Views\Widget; namespace Friendica\Directory\Views\Widget;
/** /**
* @author Hypolite Petovan <mrpetovan@gmail.com> * @author Hypolite Petovan <hypolite@mrpetovan.com>
*/ */
class PopularTags class PopularTags
{ {
@ -24,7 +24,11 @@ class PopularTags
public function render(): string public function render(): string
{ {
$stmt = 'SELECT `term`, COUNT(*) AS `total` FROM `tag` GROUP BY `term` ORDER BY COUNT(`term`) DESC LIMIT 10'; $stmt = 'SELECT `term`, COUNT(*) AS `total`
FROM `tag`
GROUP BY `term`
ORDER BY `total` DESC
LIMIT 10';
$tags = $this->connection->fetchAll($stmt); $tags = $this->connection->fetchAll($stmt);
$vars = [ $vars = [

View file

@ -1,6 +1,6 @@
<?php <?php
use Interop\Container\ContainerInterface; use Psr\Container\ContainerInterface;
// DIC configuration // DIC configuration
@ -25,7 +25,12 @@ $container['escaper'] = function (ContainerInterface $c): Zend\Escaper\Escaper {
// view renderer // view renderer
$container['renderer'] = function (ContainerInterface $c): Friendica\Directory\Views\PhpRenderer { $container['renderer'] = function (ContainerInterface $c): Friendica\Directory\Views\PhpRenderer {
$settings = $c->get('settings')['renderer']; $settings = $c->get('settings')['renderer'];
return new Friendica\Directory\Views\PhpRenderer($c->get('escaper'), $c->get('l10n'), $settings['template_path']); return new Friendica\Directory\Views\PhpRenderer(
$c->get('escaper'),
$c->get('l10n'),
$c->get('router'),
$settings['template_path']
);
}; };
// monolog // monolog
@ -84,54 +89,68 @@ $container['migration'] = function (ContainerInterface $c): ByJG\DbMigration\Mig
return $migration; return $migration;
}; };
$container['http'] = function (ContainerInterface $c): GuzzleHttp\ClientInterface {
$version = file_get_contents(__DIR__ . '/../VERSION');
if (!$version || !preg_match('/^\s*\d\.\d\.\d\s*$/', $version)) {
$version = '0.0.0';
}
return new GuzzleHttp\Client(['timeout' => 20, 'headers' => ['User-Agent' => 'FriendicaDirectory/' . trim($version) . ' ' . \GuzzleHttp\default_user_agent()]]);
};
$container['defaultProfilePictureSmallPath'] = __DIR__ . '/../public/assets/images/default-profile-sm.jpg';
// Internal Dependency Injection // Internal Dependency Injection
$container['\Friendica\Directory\Models\Profile'] = function (ContainerInterface $c): Friendica\Directory\Models\Profile { $container[\Friendica\Directory\Models\Profile::class] = function (ContainerInterface $c): Friendica\Directory\Models\Profile {
return new Friendica\Directory\Models\Profile($c->get('atlas')); return new Friendica\Directory\Models\Profile($c->get('atlas'));
}; };
$container['\Friendica\Directory\Models\ProfilePollQueue'] = function (ContainerInterface $c): Friendica\Directory\Models\ProfilePollQueue { $container[\Friendica\Directory\Models\ProfilePollQueue::class] = function (ContainerInterface $c): Friendica\Directory\Models\ProfilePollQueue {
return new Friendica\Directory\Models\ProfilePollQueue($c->get('atlas')); return new Friendica\Directory\Models\ProfilePollQueue($c->get('atlas'));
}; };
$container['\Friendica\Directory\Models\Server'] = function (ContainerInterface $c): Friendica\Directory\Models\Server { $container[\Friendica\Directory\Models\Server::class] = function (ContainerInterface $c): Friendica\Directory\Models\Server {
return new Friendica\Directory\Models\Server($c->get('atlas')); return new Friendica\Directory\Models\Server($c->get('atlas'));
}; };
$container['\Friendica\Directory\Pollers\Directory'] = function (ContainerInterface $c): Friendica\Directory\Pollers\Directory { $container[\Friendica\Directory\Pollers\Directory::class] = function (ContainerInterface $c): Friendica\Directory\Pollers\Directory {
$settings = $c->get('settings')['poller']; $settings = $c->get('settings')['poller'];
return new Friendica\Directory\Pollers\Directory( return new Friendica\Directory\Pollers\Directory(
$c->get('atlas'), $c->get('http'),
$c->get('\Friendica\Directory\Models\ProfilePollQueue'), $c->get(\Friendica\Directory\Models\ProfilePollQueue::class),
$c->get('logger'), $c->get('logger'),
$settings ?: [] $settings ?: []
); );
}; };
$container['\Friendica\Directory\Pollers\Profile'] = function (ContainerInterface $c): Friendica\Directory\Pollers\Profile { $container[\Friendica\Directory\Pollers\Profile::class] = function (ContainerInterface $c): Friendica\Directory\Pollers\Profile {
$settings = $c->get('settings')['poller']; $settings = $c->get('settings')['poller'];
return new Friendica\Directory\Pollers\Profile( return new Friendica\Directory\Pollers\Profile(
$c->get('atlas'), $c->get('atlas'),
$c->get('\Friendica\Directory\Models\Server'), $c->get('http'),
$c->get('\Friendica\Directory\Models\Profile'), $c->get(\Friendica\Directory\Models\Server::class),
$c->get(\Friendica\Directory\Models\Profile::class),
$c->get('logger'), $c->get('logger'),
$settings ?: [] $settings ?: []
); );
}; };
$container['\Friendica\Directory\Pollers\Server'] = function (ContainerInterface $c): Friendica\Directory\Pollers\Server { $container[\Friendica\Directory\Pollers\Server::class] = function (ContainerInterface $c): Friendica\Directory\Pollers\Server {
$settings = $c->get('settings')['poller']; $settings = $c->get('settings')['poller'];
return new Friendica\Directory\Pollers\Server( return new Friendica\Directory\Pollers\Server(
$c->get('atlas'), $c->get('atlas'),
$c->get('\Friendica\Directory\Models\ProfilePollQueue'), $c->get('http'),
$c->get('\Friendica\Directory\Models\Server'), $c->get(\Friendica\Directory\Models\ProfilePollQueue::class),
$c->get(\Friendica\Directory\Models\Server::class),
$c->get('simplecache'), $c->get('simplecache'),
$c->get('logger'), $c->get('logger'),
$settings ?: [] $settings ?: []
); );
}; };
$container['\Friendica\Directory\Views\Widget\AccountTypeTabs'] = function (ContainerInterface $c): Friendica\Directory\Views\Widget\AccountTypeTabs { $container[\Friendica\Directory\Views\Widget\AccountTypeTabs::class] = function (ContainerInterface $c): Friendica\Directory\Views\Widget\AccountTypeTabs {
return new Friendica\Directory\Views\Widget\AccountTypeTabs( return new Friendica\Directory\Views\Widget\AccountTypeTabs(
$c->get('atlas'), $c->get('atlas'),
$c->get('renderer'), $c->get('renderer'),

Binary file not shown.

View file

@ -0,0 +1,381 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: abidin toumi <abidin24@tutanota.com>, 2021\n"
"Language-Team: Arabic (https://www.transifex.com/Friendica/teams/12172/ar/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: ar\n"
"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "السابقة"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "التالية"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "الأولى"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "الأخيرة"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "أشخاص"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "اللغة"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "المنطقة"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "الإقليم"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "البلد"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "الخوادم العمومية"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "دليل فرنديكا"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "مصطلحات البحث"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "ابحث"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "ابحث"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "بدل التصفح"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "الدليل"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "الخوادم العمومية"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d نتائج لـ \"%s\""
msgstr[1] "نتيجة %d لـ \"%s\""
msgstr[2] "نتيجتان %d لـ \"%s\""
msgstr[3] "%d نتائج لـ \"%s\""
msgstr[4] "%d نتيجة لـ \"%s\""
msgstr[5] "%dنتيجة لـ \"%s\""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr ""
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr ""
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "رشح حسب المنطقة"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "رشح حسب الإقليم"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "رشح حسب الدولة"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "تابع"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "اللغة"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "رشح حسب اللغة"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "الموقع"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "ابحث عن وسم"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "ألسنة نوع الحساب"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr ""
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr ""
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "الإصدار المستقر"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "الإصدار الاختباري"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "إصدار قديم"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "المدير"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "لم يقدم أي وصف"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "زُر الخادم"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "البلدان الشائعة"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "اللغات الشائعة"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "الوسوم الشائعة"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "اللغة الافتراضية"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "المستخدِمون المعروفون"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "الكل"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "أشخاص (%d)"
msgstr[1] "أشخاص (%d)"
msgstr[2] "أشخاص (%d)"
msgstr[3] "أشخاص (%d)"
msgstr[4] "أشخاص (%d)"
msgstr[5] "أشخاص (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "الإحصائيات"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "إحصائيات الدليل"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "الملفات الشخصية"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "اللغات"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "من بين <strong>%s</strong> ملفا شخصيا عرف عن لغته هناك:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "الخوادم"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr ""
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "من بين هؤلاء هناك:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "من بين <strong>%s</strong> خادما عرف عن لغته هناك:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "الإصدارات"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "من بين <strong>%s</strong> خادما عرف عن إصداره هناك:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr ""
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s خادم متوفر (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "إصدار دليل فرنديكا %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "يوجد <strong>%s خادم عمومي (%s)</strong> مفتوح للستجيل. <a href=\"%s\">ألق نظرة عليهم!</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] "أخبار (%d)"
msgstr[1] "أخبار (%d)"
msgstr[2] "أخبار (%d)"
msgstr[3] "أخبار (%d)"
msgstr[4] "أخبار (%d)"
msgstr[5] "أخبار (%d)"
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] "منظمات (%d)"
msgstr[1] "منظمات (%d)"
msgstr[2] "منظمات (%d)"
msgstr[3] "منظمات (%d)"
msgstr[4] "منظمات (%d)"
msgstr[5] "منظمات (%d)"
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr "تقييم الصحة"
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] "لا مستخدمين %s"
msgstr[1] "مستخدم %s"
msgstr[2] "مستخدمان %s"
msgstr[3] "%s مستخدمين"
msgstr[4] "%s مستخدما"
msgstr[5] "%s مستخدم"
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr "لا شيء"
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr "سياسة التسجيل"
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr "يحتاج الموافقة"
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr "مفتوح"
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
msgstr[4] ""
msgstr[5] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Joan Bar <friendica@tutanota.com>, 2019\n"
"Language-Team: Catalan (https://www.transifex.com/Friendica/teams/12172/ca/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: ca\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "prèvia"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "següent"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Primer"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Ultim"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "gent"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Llengua"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Localitat"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Regió"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "País"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Servidors públics"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Directori de Friendica"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Termes de cerca"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Buscar"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Buscar"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Commuta la navegació"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Directori"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Servidors públics"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Paginació dels servidors principals"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Paginació dels servidors principals"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Filtra per localitat"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Filtra per Regió"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Filtra per País"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "seguir"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Llenguatge "
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr ""
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Localitat"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Etiqueta de cerca"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Pestanyes tipus compte"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "Superior%s Paginació"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr ""
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr ""
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Desenvolupar la versió"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Versió obsoleta"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Administrador"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "No es proporciona cap descripció"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Visita servidor"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Països populars"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Idiomes populars"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Etiquetes populars"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Idioma per defecte"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Usuaris coneguts"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "tots"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Estadístiques"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Estadístiques del directori"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "perfil"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Aquest directori en sap <strong>%s URL de perfil diferents</strong>."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Idiomes"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Fora de<strong>%s</strong> Els perfils que informen el seu idioma hi ha:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Servidors"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Aquest directori en sap <strong>%s URL de servidor diferents</strong>."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Daquests, nhi ha <strong>%s dominis (%s)</strong> que han estat un servidor Friendica com a mínim una vegada."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "D'aquests, hi ha:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Fora de <strong>%s</strong> hi ha servidors que informen del seu idioma:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Versions"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Fora de<strong>%s</strong> Hi ha servidors que informen de la seva versió:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Daquests, nhi ha <strong>%s perfil (%s)</strong> que va optar al directori públic almenys una vegada."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s servidors disponibles (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Versió del directori Friendica"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -2,13 +2,13 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"Last-Translator: Aditoo, 2018\n" "Last-Translator: Aditoo, 2019\n"
"Language-Team: Czech (https://www.transifex.com/Friendica/teams/12172/cs/)\n" "Language-Team: Czech (https://www.transifex.com/Friendica/teams/12172/cs/)\n"
"MIME-Version: 1.0\n" "MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n" "POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-17 08:11-0500\n" "PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: cs\n" "Language: cs\n"
"Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n" "Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"
"X-Generator: Poedit 2.2\n" "X-Generator: Poedit 2.2\n"
@ -31,31 +31,31 @@ msgstr "První"
msgid "Last" msgid "Last"
msgstr "Poslední" msgstr "Poslední"
#: src\classes\Controllers\Web\Directory.php:73 #: src\classes\Controllers\Web\Directory.php:85
msgid "People" msgid "People"
msgstr "Lidé" msgstr "Lidé"
#: src\classes\Controllers\Web\Search.php:66 #: src\classes\Controllers\Web\Search.php:72
msgctxt "field" msgctxt "field"
msgid "Language" msgid "Language"
msgstr "Jazyk" msgstr "Jazyk"
#: src\classes\Controllers\Web\Search.php:67 #: src\classes\Controllers\Web\Search.php:73
msgctxt "field" msgctxt "field"
msgid "Locality" msgid "Locality"
msgstr "Poloha" msgstr "Poloha"
#: src\classes\Controllers\Web\Search.php:68 #: src\classes\Controllers\Web\Search.php:74
msgctxt "field" msgctxt "field"
msgid "Region" msgid "Region"
msgstr "Region/kraj" msgstr "Region/kraj"
#: src\classes\Controllers\Web\Search.php:69 #: src\classes\Controllers\Web\Search.php:75
msgctxt "field" msgctxt "field"
msgid "Country" msgid "Country"
msgstr "Země" msgstr "Země"
#: src\classes\Controllers\Web\Servers.php:88 #: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers" msgid "Public Servers"
msgstr "Veřejné servery" msgstr "Veřejné servery"
@ -78,7 +78,7 @@ msgstr "Termíny vyhledávání"
#: src\templates\search.phtml:11 #: src\templates\search.phtml:11
msgctxt "noun" msgctxt "noun"
msgid "Search" msgid "Search"
msgstr "Hledat" msgstr "Hledání"
#: src\templates\layout.phtml:27 #: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47 #: src\templates\layout.phtml:47
@ -107,11 +107,11 @@ msgstr[1] "%d výsledky pro „%s“"
msgstr[2] "%d výsledku pro „%s“" msgstr[2] "%d výsledku pro „%s“"
msgstr[3] "%d výsledků pro „%s“" msgstr[3] "%d výsledků pro „%s“"
#: src\templates\servers.phtml:2 #: src\templates\servers.phtml:7
msgid "Top servers pagination" msgid "Top servers pagination"
msgstr "Horní stránkování serverů" msgstr "Horní stránkování serverů"
#: src\templates\servers.phtml:12 #: src\templates\servers.phtml:17
msgid "Bottom servers pagination" msgid "Bottom servers pagination"
msgstr "Spodní stránkování serverů" msgstr "Spodní stránkování serverů"
@ -128,23 +128,27 @@ msgid "Filter by country"
msgstr "Filtrovat dle země" msgstr "Filtrovat dle země"
#: src\templates\sub\profile.phtml:31 #: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb" msgctxt "verb"
msgid "Follow" msgid "Follow"
msgstr "Sledovat" msgstr "Sledovat"
#: src\templates\sub\profile.phtml:47 #: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language" msgid "Language"
msgstr "Jazyk" msgstr "Jazyk"
#: src\templates\sub\profile.phtml:50 #: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language" msgid "Filter by language"
msgstr "Filtrovat dle jazyka" msgstr "Filtrovat dle jazyka"
#: src\templates\sub\profile.phtml:56 #: src\templates\sub\profile.phtml:66
msgid "Location" msgid "Location"
msgstr "Poloha" msgstr "Poloha"
#: src\templates\sub\profile.phtml:69 #: src\templates\sub\profile.phtml:79
msgid "Search Tag" msgid "Search Tag"
msgstr "Hledat podle štítku" msgstr "Hledat podle štítku"
@ -162,10 +166,12 @@ msgstr "Horní stránkování %s"
msgid "Bottom %s pagination" msgid "Bottom %s pagination"
msgstr "Spodní stránkování %s" msgstr "Spodní stránkování %s"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15 #: src\templates\sub\server.phtml:15
msgid "Stable Version" msgid "Stable Version"
msgstr "Stabilní verze" msgstr "Stabilní verze"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17 #: src\templates\sub\server.phtml:17
msgid "Develop Version" msgid "Develop Version"
msgstr "Vývojová verze" msgstr "Vývojová verze"
@ -174,15 +180,15 @@ msgstr "Vývojová verze"
msgid "Outdated Version" msgid "Outdated Version"
msgstr "Neaktuální verze" msgstr "Neaktuální verze"
#: src\templates\sub\server.phtml:55 #: src\templates\sub\server.phtml:69
msgid "Admin" msgid "Admin"
msgstr "Administrátor" msgstr "Administrátor"
#: src\templates\sub\server.phtml:62 #: src\templates\sub\server.phtml:76
msgid "No description provided" msgid "No description provided"
msgstr "Není zadán žádný popis" msgstr "Není zadán žádný popis"
#: src\templates\sub\server.phtml:65 #: src\templates\sub\server.phtml:79
msgid "Visit Server" msgid "Visit Server"
msgstr "Navštívit server" msgstr "Navštívit server"
@ -190,7 +196,7 @@ msgstr "Navštívit server"
msgid "Popular Countries" msgid "Popular Countries"
msgstr "Populární země" msgstr "Populární země"
#: src\templates\widget\popularlanguages.phtml:2 #: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages" msgid "Popular Languages"
msgstr "Populární jazyky" msgstr "Populární jazyky"
@ -207,25 +213,157 @@ msgstr "Výchozí jazyk"
msgid "Known Users" msgid "Known Users"
msgstr "Známí uživatelé" msgstr "Známí uživatelé"
#: src\classes\Views\Widget\AccountTypeTabs.php:45 #: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type" msgctxt "account-type"
msgid "All" msgid "All"
msgstr "" msgstr "Vše"
#: src\classes\Views\Widget\AccountTypeTabs.php:53 #: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type" msgctxt "account-type"
msgid "People (%d)" msgid "People (%d)"
msgid_plural "People (%d)" msgid_plural "People (%d)"
msgstr[0] "Lidé (%d)"
msgstr[1] "Lidé (%d)"
msgstr[2] "Lidé (%d)"
msgstr[3] "Lidé (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statistika"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Statistika adresáře"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profily"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Tento adresář ví o <strong>%s zřetelných potenciálních profilových URL adresách</strong>."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Jazyky"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Ze všech <strong>%s</strong> profilů hlásících svůj jazyk je tu:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Servery"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Tento adresář ví o <strong>%s zřetelných potenciálních serverových URL adresách</strong>."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Z těch je tu <strong>%s domén (%s)</strong>, které byly alespoň jednou serverem Friendica."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Z těch je tu:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Ze všech <strong>%s</strong> serverů hlásících svůj jazyk je tu:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Verze"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Ze všech <strong>%s</strong> serverů hlásících svou verzi je tu:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Z těch je tu <strong>%s profilů (%s)</strong>, které byly alespoň jednou publikovány ve veřejném adresáři."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s dostupných serverů (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Adresář Friendica, verze %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
msgstr[2] "" msgstr[2] ""
msgstr[3] "" msgstr[3] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:54 #: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type" msgctxt "account-type"
msgid "Forum (%d)" msgid "Organization (%d)"
msgid_plural "Forums (%d)" msgid_plural "Organizations (%d)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
msgstr[2] "" msgstr[2] ""
msgstr[3] "" msgstr[3] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Anton <dev@atjn.dk>, 2022\n"
"Language-Team: Danish (Denmark) (https://www.transifex.com/Friendica/teams/12172/da_DK/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: da_DK\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Forrige"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Næste"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Første"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Sidste"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "Mennesker"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Sprog"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Lokalitet"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Region"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Land"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Offentlige servere"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Friendica adressebog"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Søgetermer"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Søg"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Søg"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Skift navigation"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Adressebog"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Offentlige servere"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d resultat for \"%s\""
msgstr[1] "%d resultater for \"%s\""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Top servere sideopdeling"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Bundservere sideopdeling"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Filtrer efter lokalitet"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Filtrer efter region"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Filtrer efter land"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Følg"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Sprog"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Filtrer efter sprog"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Placering"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Søgetag"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Kontotypefaner"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "Top %s sideopdeling"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr "Bund %s sideopdeling"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Stabil version"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Udviklingsversion"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Forældet version"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Admin"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "Ingen beskrivelse givet"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Besøg server"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Populære lande"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Populære sprog"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Populære tags"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Standard sprog"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Kendte brugere"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "Alle"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "Mennesker (%d)"
msgstr[1] "Mennesker (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statistik"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Adressebog statistik"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profiler"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Denne adressebog kender til <strong>%s særskilte potentielle profil-URL'er</strong>."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Sprog"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Ud af <strong>%s</strong> profiler som rapporterer deres sprog, er der:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Servere"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Denne adressebog kender til <strong>%s særskilte potentielle server-URL'er</strong>."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Ud af dem er der <strong>%s domæner (%s)</strong> som har været en Friendica server mindst én gang."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Ud af dem er der:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Ud af <strong>%s</strong> servere som rapporterer deres sprog, er der:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Versioner"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Ud af <strong>%s</strong> servere som rapporterer deres version, er der:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Ud af dem er der <strong>%s profiler (%s)</strong> som tilvalgte den offentlige adressebog mindst én gang."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s tilgængelige servere (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Friendica adressebogsversion %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr "Ud af dem er der i øjeblikket <strong>%s tilgængelige profiler (%s)</strong>. <a href=\"%s\">Tjek dem ud!</a>"
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "<strong>%s offentlige servere (%s)</strong> åben for registrering lige nu. <a href=\"%s\">Tjek dem ud!</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] "Nyheder (%d)"
msgstr[1] "Nyheder (%d)"
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] "Organisationer (%d)"
msgstr[1] "Organisationer (%d)"
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr "Sundhedsscore"
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] "%s bruger"
msgstr[1] "%s brugere"
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr "Ingen"
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr "Registreringspolitik"
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr "Ved godkendelse"
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr "Åben"
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Tobias Diekershoff <tobias.diekershoff@gmx.net>, 2020\n"
"Language-Team: German (https://www.transifex.com/Friendica/teams/12172/de/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: de\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Vorherige"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Nächste"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Erste"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Letzte"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "Leute"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Sprache"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Wohnort"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Region"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Land"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Öffentlicher Server"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Friendica Verzeichnis"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Suchbegriff"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Suche"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Suche"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Schalte Navigation"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Verzeichnis"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Öffentliche Server"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d Ergebnisse für \"%s\""
msgstr[1] "%d Ergebnisse für \"%s\""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Höchste Serverwertung"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Niedrigste Serverwertung"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Filter nach Ort"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Filter nach Region"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Filter nach Land"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Folge"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Sprache"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Filter nach Sprache"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Ort"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Suchbegriff"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Konto-Typ Register"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "Top %s pagination"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr "Bottom %s pagination"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Stabile Version"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Entwickler Version"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Abgelaufene Version"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Admin"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "Keine Beschreibung angeboten"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Besuche den Server"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Häufige Länder"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Häufige Sprachen"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Beliebte Tags"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Standard Sprache"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Bekannte Nutzer"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "Alle"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "Personen (%d)"
msgstr[1] "Personen (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statistik"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Verzeichnis Statistiken"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profile"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Dieses Verzeichnis kennt <strong>%s unterschiedliche, potentielle Profil URLs</strong>"
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Sprachen"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Von den <strong>%s</strong> Profilen, die ihre Sprache angeben, sind:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Server"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Dieses Verzeichnis kennt <strong>%s unterschiedliche, potentielle Server URLs</strong>"
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Von diesen gibt es <strong>%sDomänen(%s)</strong>, die zumindest einmal Friendica Knoten gewesen sind."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Von diesen sind:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Von den <strong>%s</strong> Servern, die ihre Spracheinstellung angeben, sind:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Versionen"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Von den <strong>%s</strong> Servern, die ihre Version angeben, sind:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Von diesen gibt es <strong>%sProfile (%s)</strong> die sich, zumindest einmal, für die Aufnahme in das öffentliche Verzeichnis entschlossen haben."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%sverfügbare Server (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Friendica Verzeichnis Version %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr "Von diesen sind derzeit <strong>%sverfügbare Profile (%s)</strong>. <a href=\"%s\">Schaue sie dir an!</a>"
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "<strong>%s öffentliche Server (%s)</strong> erlauben derzeit die Anmeldung. <a href=\"%s\">Schau sie dir an!</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

View file

@ -31,31 +31,31 @@ msgstr ""
msgid "Last" msgid "Last"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Directory.php:73 #: src\classes\Controllers\Web\Directory.php:85
msgid "People" msgid "People"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Search.php:66 #: src\classes\Controllers\Web\Search.php:72
msgctxt "field" msgctxt "field"
msgid "Language" msgid "Language"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Search.php:67 #: src\classes\Controllers\Web\Search.php:73
msgctxt "field" msgctxt "field"
msgid "Locality" msgid "Locality"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Search.php:68 #: src\classes\Controllers\Web\Search.php:74
msgctxt "field" msgctxt "field"
msgid "Region" msgid "Region"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Search.php:69 #: src\classes\Controllers\Web\Search.php:75
msgctxt "field" msgctxt "field"
msgid "Country" msgid "Country"
msgstr "" msgstr ""
#: src\classes\Controllers\Web\Servers.php:88 #: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers" msgid "Public Servers"
msgstr "" msgstr ""
@ -105,11 +105,11 @@ msgid_plural "%d results for \"%s\""
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src\templates\servers.phtml:2 #: src\templates\servers.phtml:7
msgid "Top servers pagination" msgid "Top servers pagination"
msgstr "" msgstr ""
#: src\templates\servers.phtml:12 #: src\templates\servers.phtml:17
msgid "Bottom servers pagination" msgid "Bottom servers pagination"
msgstr "" msgstr ""
@ -126,23 +126,27 @@ msgid "Filter by country"
msgstr "" msgstr ""
#: src\templates\sub\profile.phtml:31 #: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb" msgctxt "verb"
msgid "Follow" msgid "Follow"
msgstr "" msgstr ""
#: src\templates\sub\profile.phtml:47 #: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language" msgid "Language"
msgstr "" msgstr ""
#: src\templates\sub\profile.phtml:50 #: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language" msgid "Filter by language"
msgstr "" msgstr ""
#: src\templates\sub\profile.phtml:56 #: src\templates\sub\profile.phtml:66
msgid "Location" msgid "Location"
msgstr "" msgstr ""
#: src\templates\sub\profile.phtml:69 #: src\templates\sub\profile.phtml:79
msgid "Search Tag" msgid "Search Tag"
msgstr "" msgstr ""
@ -160,10 +164,12 @@ msgstr ""
msgid "Bottom %s pagination" msgid "Bottom %s pagination"
msgstr "" msgstr ""
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15 #: src\templates\sub\server.phtml:15
msgid "Stable Version" msgid "Stable Version"
msgstr "" msgstr ""
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17 #: src\templates\sub\server.phtml:17
msgid "Develop Version" msgid "Develop Version"
msgstr "" msgstr ""
@ -172,15 +178,15 @@ msgstr ""
msgid "Outdated Version" msgid "Outdated Version"
msgstr "" msgstr ""
#: src\templates\sub\server.phtml:55 #: src\templates\sub\server.phtml:69
msgid "Admin" msgid "Admin"
msgstr "" msgstr ""
#: src\templates\sub\server.phtml:62 #: src\templates\sub\server.phtml:76
msgid "No description provided" msgid "No description provided"
msgstr "" msgstr ""
#: src\templates\sub\server.phtml:65 #: src\templates\sub\server.phtml:79
msgid "Visit Server" msgid "Visit Server"
msgstr "" msgstr ""
@ -188,7 +194,7 @@ msgstr ""
msgid "Popular Countries" msgid "Popular Countries"
msgstr "" msgstr ""
#: src\templates\widget\popularlanguages.phtml:2 #: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages" msgid "Popular Languages"
msgstr "" msgstr ""
@ -205,21 +211,147 @@ msgstr ""
msgid "Known Users" msgid "Known Users"
msgstr "" msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:45 #: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type" msgctxt "account-type"
msgid "All" msgid "All"
msgstr "" msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:53 #: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type" msgctxt "account-type"
msgid "People (%d)" msgid "People (%d)"
msgid_plural "People (%d)" msgid_plural "People (%d)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:54 #: src\templates\layout.phtml:97
msgid "Stats"
msgstr ""
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr ""
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr ""
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr ""
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr ""
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr ""
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr ""
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr ""
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr ""
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr ""
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr ""
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr ""
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr ""
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr ""
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type" msgctxt "account-type"
msgid "Forum (%d)" msgid "News (%d)"
msgid_plural "Forums (%d)" msgid_plural "News (%d)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Andy H3 <andy@hubup.pro>, 2020\n"
"Language-Team: English (United Kingdom) (https://www.transifex.com/Friendica/teams/12172/en_GB/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: en_GB\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Previous"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Next"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "First"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Last"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "People"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Language"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Locality"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Region"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Country"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Public servers"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Friendica directory"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Search terms"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Search"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Search"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Toggle navigation"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Directory"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Public servers"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d result for \"%s\""
msgstr[1] "%d results for \"%s\""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Top servers pagination"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Bottom servers pagination"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Filter by locality"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Filter by region"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Filter by country"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Follow"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Language"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Filter by language"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Location"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Search tag"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Account type tabs"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "Top %s pagination"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr "Bottom %s pagination"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Stable version"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Develop version"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Outdated version"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Admin"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "No description provided"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Visit server"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Popular countries"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Popular languages"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Popular tags"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Default language"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Known users"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "All"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "People (%d)"
msgstr[1] "People (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Stats"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Directory statistics"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profiles"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "This directory knows about <strong>%s distinct potential profile URLs</strong>."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Languages"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Out of <strong>%s</strong> profiles reporting their language there are:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Servers"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "This directory knows about <strong>%s distinct potential server URLs</strong>."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Out of those, there are:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Out of <strong>%s</strong> servers reporting their language there are:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Versions"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Out of <strong>%s</strong> servers reporting their version there are:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s available servers (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Friendica directory version %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Rain Hawk, 2019\n"
"Language-Team: Estonian (https://www.transifex.com/Friendica/teams/12172/et/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: et\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Eelmine"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Järgmine"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Esimene"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Viimane"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "Inimesed"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Keel"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Asukoht"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Regioon"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Riik"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Avalikud serverid"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Friendica Kataloog"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Otsingu tingimused"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Otsi"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Otsi"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Vaheta navigatsiooni"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Kataloog"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Avalikud serverid"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr ""
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr ""
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Filtreeri asukohajärgselt"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Filtreeri regionaalselt"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Filtreeri riigi järgi"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Järgi"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Keel"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Filtreeri keele järgi"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Asukoht"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Otsingu tag"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Konto tüübi sakid"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr ""
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr ""
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Stabiilne versioon"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Arendusversioon"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Aegunud versioon"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Adminn"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "Kirjeldus pole saadaval"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Külasta serverit"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Populaarsed riigid"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Populaarsed keeled"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Polulaarsed tag`id"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Peamine keel"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Tuntud kasutajad"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "Kõik"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "Inimesed ( %d )"
msgstr[1] "Inimesed (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statistika"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Kataloogi statistika"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profiilid"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Keeled"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr ""
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Serverid"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr ""
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr ""
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr ""
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr ""
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr ""
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr ""
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr ""
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr ""
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -2,22 +2,24 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"Last-Translator: \n" "Last-Translator: Vladimir Núñez <lapoubelle111@gmail.com>, 2018\n"
"Language-Team: \n" "Language-Team: French (https://www.transifex.com/Friendica/teams/12172/fr/)\n"
"MIME-Version: 1.0\n" "MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n" "POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-17 08:53-0500\n" "PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: fr\n" "Language: fr\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n"
"X-Generator: Poedit 2.2\n" "X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168 src\classes\Content\Pager.php:216 #: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous" msgid "Previous"
msgstr "Précédent" msgstr "Précédent"
#: src\classes\Content\Pager.php:173 src\classes\Content\Pager.php:273 #: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next" msgid "Next"
msgstr "Suivant" msgstr "Suivant"
@ -29,51 +31,57 @@ msgstr "Début"
msgid "Last" msgid "Last"
msgstr "Fin" msgstr "Fin"
#: src\classes\Controllers\Web\Directory.php:73 #: src\classes\Controllers\Web\Directory.php:85
msgid "People" msgid "People"
msgstr "Utilisateurs" msgstr "Utilisateurs"
#: src\classes\Controllers\Web\Search.php:66 #: src\classes\Controllers\Web\Search.php:72
msgctxt "field" msgctxt "field"
msgid "Language" msgid "Language"
msgstr "Langue" msgstr "Langue"
#: src\classes\Controllers\Web\Search.php:67 #: src\classes\Controllers\Web\Search.php:73
msgctxt "field" msgctxt "field"
msgid "Locality" msgid "Locality"
msgstr "Localité" msgstr "Localité"
#: src\classes\Controllers\Web\Search.php:68 #: src\classes\Controllers\Web\Search.php:74
msgctxt "field" msgctxt "field"
msgid "Region" msgid "Region"
msgstr "Région" msgstr "Région"
#: src\classes\Controllers\Web\Search.php:69 #: src\classes\Controllers\Web\Search.php:75
msgctxt "field" msgctxt "field"
msgid "Country" msgid "Country"
msgstr "Pays" msgstr "Pays"
#: src\classes\Controllers\Web\Servers.php:88 #: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers" msgid "Public Servers"
msgstr "Serveurs publics" msgstr "Serveurs publics"
#: src\templates\layout.phtml:4 src\templates\layout.phtml:18 #: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory" msgid "Friendica Directory"
msgstr "Répertoire Friendica" msgstr "Répertoire Friendica"
#: src\templates\layout.phtml:23 src\templates\layout.phtml:25 #: src\templates\layout.phtml:23
#: src\templates\layout.phtml:43 src\templates\layout.phtml:45 #: src\templates\layout.phtml:25
#: src\templates\search.phtml:4 src\templates\search.phtml:12 #: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms" msgid "Search terms"
msgstr "Mots-clés" msgstr "Mots-clés"
#: src\templates\layout.phtml:24 src\templates\layout.phtml:45 #: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11 #: src\templates\search.phtml:11
msgctxt "noun" msgctxt "noun"
msgid "Search" msgid "Search"
msgstr "Recherche" msgstr "Recherche"
#: src\templates\layout.phtml:27 src\templates\layout.phtml:47 #: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14 #: src\templates\search.phtml:14
msgctxt "verb" msgctxt "verb"
msgid "Search" msgid "Search"
@ -97,11 +105,11 @@ msgid_plural "%d results for \"%s\""
msgstr[0] "%d résultat pour \"%s\"" msgstr[0] "%d résultat pour \"%s\""
msgstr[1] "%d résultats pour \"%s\"" msgstr[1] "%d résultats pour \"%s\""
#: src\templates\servers.phtml:2 #: src\templates\servers.phtml:7
msgid "Top servers pagination" msgid "Top servers pagination"
msgstr "Pagination des serveurs haute" msgstr "Pagination des serveurs haute"
#: src\templates\servers.phtml:12 #: src\templates\servers.phtml:17
msgid "Bottom servers pagination" msgid "Bottom servers pagination"
msgstr "Pagination des serveurs basse" msgstr "Pagination des serveurs basse"
@ -118,23 +126,27 @@ msgid "Filter by country"
msgstr "Filtrer par pays" msgstr "Filtrer par pays"
#: src\templates\sub\profile.phtml:31 #: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb" msgctxt "verb"
msgid "Follow" msgid "Follow"
msgstr "Suivre" msgstr "Suivre"
#: src\templates\sub\profile.phtml:47 #: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language" msgid "Language"
msgstr "Langue" msgstr "Langue"
#: src\templates\sub\profile.phtml:50 #: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language" msgid "Filter by language"
msgstr "Filtrer par langue" msgstr "Filtrer par langue"
#: src\templates\sub\profile.phtml:56 #: src\templates\sub\profile.phtml:66
msgid "Location" msgid "Location"
msgstr "Localisation" msgstr "Localisation"
#: src\templates\sub\profile.phtml:69 #: src\templates\sub\profile.phtml:79
msgid "Search Tag" msgid "Search Tag"
msgstr "Rechercher ce tag" msgstr "Rechercher ce tag"
@ -142,18 +154,22 @@ msgstr "Rechercher ce tag"
msgid "Account type tabs" msgid "Account type tabs"
msgstr "Onglets de type de compte" msgstr "Onglets de type de compte"
#: src\templates\sub\profiles.phtml:4 src\templates\sub\profiles.phtml:7 #: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination" msgid "Top %s pagination"
msgstr "Pagination %s haute" msgstr "Pagination %s haute"
#: src\templates\sub\profiles.phtml:13 src\templates\sub\profiles.phtml:16 #: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination" msgid "Bottom %s pagination"
msgstr "Pagination %s basse" msgstr "Pagination %s basse"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15 #: src\templates\sub\server.phtml:15
msgid "Stable Version" msgid "Stable Version"
msgstr "Version stable" msgstr "Version stable"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17 #: src\templates\sub\server.phtml:17
msgid "Develop Version" msgid "Develop Version"
msgstr "Version instable" msgstr "Version instable"
@ -162,15 +178,15 @@ msgstr "Version instable"
msgid "Outdated Version" msgid "Outdated Version"
msgstr "Version périmée" msgstr "Version périmée"
#: src\templates\sub\server.phtml:55 #: src\templates\sub\server.phtml:69
msgid "Admin" msgid "Admin"
msgstr "Administrateur" msgstr "Administrateur"
#: src\templates\sub\server.phtml:62 #: src\templates\sub\server.phtml:76
msgid "No description provided" msgid "No description provided"
msgstr "Pas de description fournie" msgstr "Pas de description fournie"
#: src\templates\sub\server.phtml:65 #: src\templates\sub\server.phtml:79
msgid "Visit Server" msgid "Visit Server"
msgstr "Visiter ce serveur" msgstr "Visiter ce serveur"
@ -178,7 +194,7 @@ msgstr "Visiter ce serveur"
msgid "Popular Countries" msgid "Popular Countries"
msgstr "Pays populaires" msgstr "Pays populaires"
#: src\templates\widget\popularlanguages.phtml:2 #: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages" msgid "Popular Languages"
msgstr "Language populaires" msgstr "Language populaires"
@ -186,7 +202,8 @@ msgstr "Language populaires"
msgid "Popular Tags" msgid "Popular Tags"
msgstr "Tags populaires" msgstr "Tags populaires"
#: src\templates\sub\server.phtml:44 src\templates\sub\server.phtml:45 #: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language" msgid "Default Language"
msgstr "Langage de base" msgstr "Langage de base"
@ -194,21 +211,147 @@ msgstr "Langage de base"
msgid "Known Users" msgid "Known Users"
msgstr "Utilisateurs connus" msgstr "Utilisateurs connus"
#: src\classes\Views\Widget\AccountTypeTabs.php:45 #: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type" msgctxt "account-type"
msgid "All" msgid "All"
msgstr "Tous" msgstr "Tout"
#: src\classes\Views\Widget\AccountTypeTabs.php:53 #: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type" msgctxt "account-type"
msgid "People (%d)" msgid "People (%d)"
msgid_plural "People (%d)" msgid_plural "People (%d)"
msgstr[0] "Utilisateur (%d)" msgstr[0] ""
msgstr[1] "Utilisateurs (%d)" msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:54 #: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statistiques"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Statistiques d'annuaire"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profils"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Langages"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "parmi <strong>%s</strong>profil mentionnant leur langage il y a:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Serveurs"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr ""
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr ""
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Parmi ceux-là, il y a:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr ""
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Versions"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Parmi <strong>%s</strong> serveurs mentionnant leur version il y a:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr ""
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%sserveurs disponibles(%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Friendica Annuaire version %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr ""
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type" msgctxt "account-type"
msgid "Forum (%d)" msgid "News (%d)"
msgid_plural "Forums (%d)" msgid_plural "News (%d)"
msgstr[0] "Forum (%s)" msgstr[0] ""
msgstr[1] "Forums (%d)" msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr ""
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] ""
msgstr[1] ""
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr ""
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr ""
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr ""
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,369 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: GunChleoc, 2021\n"
"Language-Team: Gaelic, Scottish (https://www.transifex.com/Friendica/teams/12172/gd/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: gd\n"
"Plural-Forms: nplurals=4; plural=(n==1 || n==11) ? 0 : (n==2 || n==12) ? 1 : (n > 2 && n < 20) ? 2 : 3;\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Air ais"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Air adhart"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Toiseach"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Deireadh"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "Daoine"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Cànan"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Ionad"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Sgìre"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Dùthaich"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Frithealaichean poblach"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Eòlaire Friendica"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Faclan-luirg"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Lorg"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Lorg"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Toglaich an t-seòladaireachd"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Eòlaire"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Frithealaichean poblach"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d toradh airson “%s”"
msgstr[1] "%d thoradh airson “%s”"
msgstr[2] "%d thoraidhean airson “%s”"
msgstr[3] "%d toradh airson “%s”"
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Duilleagachadh fhrithealaichean aig a bhàrr"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Duilleagachadh fhrithealaichean aig a bhonn"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Criathraich a-rèir ionaid"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Criathraich a-rèir sgìre"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Criathraich a-rèir dùthcha"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Lean air"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Cànan"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Criathraich a-rèir cànain"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Ionad"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Taga luirg"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Tabaichean seòrsa a chunntais"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "Duilleagachadh %s aig a bhàrr"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr "Duilleagachadh %s aig a bhonn"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Tionndadh seasmhach"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Tionndadh leasachaidh"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Seann-tionndadh"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Rianaire"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "Cha deach tuairisgeul a sholarachadh"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Tadhail air frithealaiche"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Dùthchannan fèillmhor"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Cànanan fèillmhor"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Tagaichean fèillmhor"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "An cànan tùsail"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Cleachdaichean as aithne"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "Na h-uile"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "Daoine (%d)"
msgstr[1] "Daoine (%d)"
msgstr[2] "Daoine (%d)"
msgstr[3] "Daoine (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Stadastaireachd"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Staitistearachd an eòlaire"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Pròifilean"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Fhuair an t-eòlaire lorg air <strong>%s URL gu pròifilean fa leth</strong>."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Cànanan"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "Am measg <strong>%s</strong> pròifil a dhinnseas an cànan, tha:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Frithealaichean"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Fhuair an t-eòlaire lorg air <strong>%s URL gu frithealaichean fa leth</strong>."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Tha <strong>%s àrainn (%s)</strong> nam measg a tha nam frithealaichean Friendica no a bha uair."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Am measg an fheadhainn sin, tha:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "Am measg <strong>%s</strong> frithealaiche a dhinnseas an cànan, tha:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Tionndaidhean"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "Am measg <strong>%s</strong> frithealaiche a dhinnseas an tionndadh, tha:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Am measg an fhadhainn sin, tha <strong>%s pròifil (%s)</strong> a tha ag aontachadh ri gabhail a-steach dhan eòlaire poblach no a dhaontaich ris uair."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s frithealaiche ri fhaighinn (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Eòlaire Friendica tionndadh %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr "Am measg an fheadhainn sin, tha <strong>%s pròifilean rim faighinn (%s)</strong>. <a href=\"%s\">Nach doir thu sùil orra?</a>"
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "Tha <strong>%s frithealaichean poblach (%s)</strong> fosgailte airson clàradh. <a href=\"%s\">Nach doir thu sùil orra?</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] "Naidheachdan (%d)"
msgstr[1] "Naidheachdan (%d)"
msgstr[2] "Naidheachdan (%d)"
msgstr[3] "Naidheachdan (%d)"
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] "Buidhnean (%d)"
msgstr[1] "Buidhnean (%d)"
msgstr[2] "Buidhnean (%d)"
msgstr[3] "Buidhnean (%d)"
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr "Sgòr slàinte"
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] "%s chleachdaiche"
msgstr[1] "%s chleachdaiche"
msgstr[2] "%s cleachdaichean"
msgstr[3] "%s cleachdaiche"
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr "Chan eil gin"
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr "Poileasaidh clàraidh"
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr "Le aontachadh"
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr "Fosgailte"
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Binary file not shown.

View file

@ -0,0 +1,357 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Balázs Úr, 2021\n"
"Language-Team: Hungarian (https://www.transifex.com/Friendica/teams/12172/hu/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2018-11-16T04:17:37+00:00\n"
"PO-Revision-Date: 2018-11-16 20:30+0000\n"
"Language: hu\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2\n"
#: src\classes\Content\Pager.php:168
#: src\classes\Content\Pager.php:216
msgid "Previous"
msgstr "Előző"
#: src\classes\Content\Pager.php:173
#: src\classes\Content\Pager.php:273
msgid "Next"
msgstr "Következő"
#: src\classes\Content\Pager.php:211
msgid "First"
msgstr "Első"
#: src\classes\Content\Pager.php:278
msgid "Last"
msgstr "Utolsó"
#: src\classes\Controllers\Web\Directory.php:85
msgid "People"
msgstr "Emberek"
#: src\classes\Controllers\Web\Search.php:72
msgctxt "field"
msgid "Language"
msgstr "Nyelv"
#: src\classes\Controllers\Web\Search.php:73
msgctxt "field"
msgid "Locality"
msgstr "Helység"
#: src\classes\Controllers\Web\Search.php:74
msgctxt "field"
msgid "Region"
msgstr "Régió"
#: src\classes\Controllers\Web\Search.php:75
msgctxt "field"
msgid "Country"
msgstr "Ország"
#: src\classes\Controllers\Web\Servers.php:105
msgid "Public Servers"
msgstr "Nyilvános kiszolgálók"
#: src\templates\layout.phtml:4
#: src\templates\layout.phtml:18
msgid "Friendica Directory"
msgstr "Friendica könyvtár"
#: src\templates\layout.phtml:23
#: src\templates\layout.phtml:25
#: src\templates\layout.phtml:43
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:4
#: src\templates\search.phtml:12
msgid "Search terms"
msgstr "Kifejezések keresése"
#: src\templates\layout.phtml:24
#: src\templates\layout.phtml:45
#: src\templates\search.phtml:11
msgctxt "noun"
msgid "Search"
msgstr "Keresés"
#: src\templates\layout.phtml:27
#: src\templates\layout.phtml:47
#: src\templates\search.phtml:14
msgctxt "verb"
msgid "Search"
msgstr "Keresés"
#: src\templates\layout.phtml:33
msgid "Toggle navigation"
msgstr "Navigáció ki- és bekapcsolása"
#: src\templates\layout.phtml:55
msgid "Directory"
msgstr "Könyvtár"
#: src\templates\layout.phtml:60
msgid "Public servers"
msgstr "Nyilvános kiszolgálók"
#: src\templates\search.phtml:19
msgid "%d result for \"%s\""
msgid_plural "%d results for \"%s\""
msgstr[0] "%d találat erre: „%s”"
msgstr[1] "%d találat erre: „%s”"
#: src\templates\servers.phtml:7
msgid "Top servers pagination"
msgstr "Kiszolgálók lapszámozása felül"
#: src\templates\servers.phtml:17
msgid "Bottom servers pagination"
msgstr "Kiszolgálók lapszámozása alul"
#: src\templates\sub\profile.phtml:5
msgid "Filter by locality"
msgstr "Szűrés helység szerint"
#: src\templates\sub\profile.phtml:11
msgid "Filter by region"
msgstr "Szűrés régió szerint"
#: src\templates\sub\profile.phtml:17
msgid "Filter by country"
msgstr "Szűrés ország szerint"
#: src\templates\sub\profile.phtml:31
#: src\templates\sub\profile.phtml:35
#: src\templates\sub\profile.phtml:39
msgctxt "verb"
msgid "Follow"
msgstr "Követés"
#: src\templates\layout.phtml:65
#: src\templates\sub\profile.phtml:57
msgid "Language"
msgstr "Nyelv"
#: src\templates\sub\profile.phtml:60
#: src\templates\widget\popularserverlanguages.phtml:2
msgid "Filter by language"
msgstr "Szűrés nyelv szerint"
#: src\templates\sub\profile.phtml:66
msgid "Location"
msgstr "Hely"
#: src\templates\sub\profile.phtml:79
msgid "Search Tag"
msgstr "Címke keresése"
#: src\templates\sub\profiles.phtml:1
msgid "Account type tabs"
msgstr "Fióktípus lapok"
#: src\templates\sub\profiles.phtml:4
#: src\templates\sub\profiles.phtml:7
msgid "Top %s pagination"
msgstr "%s lapszámozása felül"
#: src\templates\sub\profiles.phtml:13
#: src\templates\sub\profiles.phtml:16
msgid "Bottom %s pagination"
msgstr "%s lapszámozása alul"
#: src\templates\statistics.phtml:66
#: src\templates\sub\server.phtml:15
msgid "Stable Version"
msgstr "Stabil verzió"
#: src\templates\statistics.phtml:68
#: src\templates\sub\server.phtml:17
msgid "Develop Version"
msgstr "Fejlesztői verzió"
#: src\templates\sub\server.phtml:19
msgid "Outdated Version"
msgstr "Elavult verzió"
#: src\templates\sub\server.phtml:69
msgid "Admin"
msgstr "Adminisztrátor"
#: src\templates\sub\server.phtml:76
msgid "No description provided"
msgstr "Nincs leírás megadva"
#: src\templates\sub\server.phtml:79
msgid "Visit Server"
msgstr "Kiszolgáló meglátogatása"
#: src\templates\widget\popularcountries.phtml:2
msgid "Popular Countries"
msgstr "Népszerű országok"
#: src\templates\widget\popularprofilelanguages.phtml:2
msgid "Popular Languages"
msgstr "Népszerű nyelvek"
#: src\templates\widget\populartags.phtml:2
msgid "Popular Tags"
msgstr "Népszerű címkék"
#: src\templates\sub\server.phtml:44
#: src\templates\sub\server.phtml:45
msgid "Default Language"
msgstr "Alapértelmezett nyelv"
#: src\templates\sub\server.phtml:49
msgid "Known Users"
msgstr "Ismert felhasználók"
#: src\classes\Views\Widget\AccountTypeTabs.php:48
msgctxt "account-type"
msgid "All"
msgstr "Összes"
#: src\classes\Views\Widget\AccountTypeTabs.php:56
msgctxt "account-type"
msgid "People (%d)"
msgid_plural "People (%d)"
msgstr[0] "Emberek (%d)"
msgstr[1] "Emberek (%d)"
#: src\templates\layout.phtml:97
msgid "Stats"
msgstr "Statisztikák"
#: src\templates\statistics.phtml:4
msgid "Directory statistics"
msgstr "Könyvtárstatisztikák"
#: src\templates\statistics.phtml:5
msgid "Profiles"
msgstr "Profilok"
#: src\templates\statistics.phtml:6
msgid "This directory knows about <strong>%s distinct potential profile URLs</strong>."
msgstr "Ez a könyvtár körülbelül <strong>%s különböző lehetséges profil URL-t</strong> ismer."
#: src\templates\statistics.phtml:16
#: src\templates\statistics.phtml:46
msgid "Languages"
msgstr "Nyelvek"
#: src\templates\statistics.phtml:17
msgid "Out of <strong>%s</strong> profiles reporting their language there are:"
msgstr "A nyelvüket jelentő <strong>%s</strong> profil közül ezek az alábbiak:"
#: src\templates\statistics.phtml:27
msgid "Servers"
msgstr "Kiszolgálók"
#: src\templates\statistics.phtml:28
msgid "This directory knows about <strong>%s distinct potential server URLs</strong>."
msgstr "Ez a könyvtár körülbelül <strong>%s különböző lehetséges kiszolgáló URL-t</strong> ismer."
#: src\templates\statistics.phtml:29
msgid "Out of those, there are <strong>%s domains (%s)</strong> that have been a Friendica server at least once."
msgstr "Ezek közül <strong>%s tartomány (%s)</strong> van, amelyek legalább egyszer Friendica kiszolgálók voltak."
#: src\templates\statistics.phtml:33
msgid "Out of those, there are:"
msgstr "Ezek közül ezek az alábbiak:"
#: src\templates\statistics.phtml:47
msgid "Out of <strong>%s</strong> servers reporting their language there are:"
msgstr "A nyelvüket jelentő <strong>%s</strong> kiszolgáló közül ezek az alábbiak:"
#: src\templates\statistics.phtml:57
msgid "Versions"
msgstr "Verziók"
#: src\templates\statistics.phtml:58
msgid "Out of <strong>%s</strong> servers reporting their version there are:"
msgstr "A verziójukat jelentő <strong>%s</strong> kiszolgáló közül ezek az alábbiak:"
#: src\templates\statistics.phtml:7
msgid "Out of those, there are <strong>%s profiles (%s)</strong> that opted in the public directory at least once."
msgstr "Ezek közül <strong>%s profil (%s)</strong> van, amelyek legalább egyszer beléptek a nyilvános könyvtárba."
#: src\templates\statistics.phtml:35
msgid "<strong>%s available servers (%s)</strong>"
msgstr "<strong>%s elérhető kiszolgáló (%s)</strong>"
#: src\templates\layout.phtml:91
msgid "Friendica Directory version %s"
msgstr "Friendica könyvtár verzió: %s"
#: src\templates\statistics.phtml:11
msgid "Out of those, there currently are <strong>%s available profiles (%s)</strong>. <a href=\"%s\">Check them out!</a>"
msgstr "Ezek közül jelenleg <strong>%s elérhető profil (%s)</strong> van. <a href=\"%s\">Nézze meg őket!</a>"
#: src\templates\statistics.phtml:39
msgid "<strong>%s public servers (%s)</strong> currently open for registration. <a href=\"%s\">Check them out!</a>"
msgstr "<strong>%s nyilvános kiszolgáló (%s)</strong> jelenleg nyitott a regisztrációra. <a href=\"%s\">Nézze meg azokat!</a>"
#: src\classes\Views\Widget\AccountTypeTabs.php:57
msgctxt "account-type"
msgid "News (%d)"
msgid_plural "News (%d)"
msgstr[0] "Hírek (%d)"
msgstr[1] "Hírek (%d)"
#: src\classes\Views\Widget\AccountTypeTabs.php:58
msgctxt "account-type"
msgid "Organization (%d)"
msgid_plural "Organizations (%d)"
msgstr[0] "Szervezet (%d)"
msgstr[1] "Szervezetek (%d)"
#: src\templates\sub\server.phtml:40
msgid "Health Score"
msgstr "Egészségpont"
#: src\templates\sub\server.phtml:52
msgid "%s User"
msgid_plural "%s Users"
msgstr[0] "%s felhasználó"
msgstr[1] "%s felhasználó"
#: src\templates\sub\server.phtml:54
msgid "None"
msgstr "Nincs"
#: src\templates\sub\server.phtml:58
#: src\templates\sub\server.phtml:62
msgid "Registration Policy"
msgstr "Regisztrációs irányelv"
#: src\templates\sub\server.phtml:59
msgid "By Approval"
msgstr "Jóváhagyás által"
#: src\templates\sub\server.phtml:63
msgid "Open"
msgstr "Nyitott"
#: src\classes\Views\Widget\AccountTypeTabs.php:61
msgctxt "account-type"
msgid "Group (%d)"
msgid_plural "Groups (%d)"
msgstr[0] ""
msgstr[1] ""
#: src\templates\servers.phtml:3
msgid "Filtered by language:"
msgstr ""
#: src\templates\servers.phtml:3
msgid "Clear language filter"
msgstr ""
#: src\templates\layout.phtml:94
msgid "Source Code on Friendica's Forgejo"
msgstr ""

Some files were not shown because too many files have changed in this diff Show more