548 Commits
3.2.1 ... 3.4.2

Author SHA1 Message Date
Mario
b655d04b34 version 3.4.2 2018-07-19 11:57:35 +02:00
Mario
7f84933cab compatibility fix for future versions 2018-07-19 11:52:12 +02:00
Mario Vavti
5fa3e10701 set the correct album name when moving photos
(cherry picked from commit eb322e8312)
2018-07-18 13:19:35 +02:00
Mario
95355ddec0 Merge branch 'patch-1' into 'master'
Fix wrong plural function logic

See merge request hubzilla/core!1226
2018-07-18 08:27:21 +02:00
kostikov
cbab7d2150 Update hmessages.po 2018-07-18 00:28:04 +02:00
kostikov
4284088611 Fix wrong plural function logic 2018-07-17 21:27:08 +02:00
zotlabs
f808a2b5a1 issue syncing pageflags 2018-07-04 19:53:51 -07:00
zotlabs
3fc955abfd hubzilla core issue #1227 - affinity slider unable to reach 0,99 when slider saved default changes 2018-06-15 15:34:27 -07:00
zotlabs
615fa1119f apply changes to slider defaults across all modules that use buildQuery for updates 2018-06-15 15:32:12 -07:00
Mike Macgirvin
fdf920b374 Merge branch 'master' into 'master'
Master

See merge request hubzilla/core!1218
2018-06-13 03:11:05 +02:00
Mike Macgirvin
dffd82cb24 Merge branch 'remove-github-from-README' into 'master'
remove github from link to INSTALL.txt

See merge request hubzilla/core!1215
2018-06-13 03:09:39 +02:00
gia vec
9840d1ce73 Update hstrings.php 2018-06-12 20:47:19 +02:00
gia vec
6a45bd4372 Update hmessages.po 2018-06-12 20:42:16 +02:00
Herbert Thielen
530bc996ca remove github from link to INSTALL.txt 2018-06-11 15:26:30 +02:00
zotlabs
2f2bd03b15 fixes for immediate expire, channel_active not initialised in DB 2018-06-10 22:19:51 -07:00
Mario Vavti
53363d6808 fix issue #1221
(cherry picked from commit d0f7b1d9b7)
2018-06-10 17:06:12 +02:00
Mario
86c0abe67e Merge branch 'dev' into 'dev'
Update symbolic link doc/es

See merge request hubzilla/core!1214

(cherry picked from commit 46cc64f2d8)

438ce44a Update symbolic link doc/es
2018-06-10 16:54:37 +02:00
Mario Vavti
2f7dfb0286 update changelog
(cherry picked from commit 7c98aea524)
2018-06-08 12:17:33 +02:00
Mario
688c5bdd20 bump version 2018-06-08 12:05:06 +02:00
Mario Vavti
752a9d904c DB update to fix wrong hubloc_url for activitypub hublocs
(cherry picked from commit eb04dbc5ce)
2018-06-08 09:41:35 +02:00
Mario Vavti
a5b9fbaf00 github to framagit transition
(cherry picked from commit 7bf1c5f27b)
2018-06-08 09:05:27 +02:00
zotlabs
d841303c04 we probably don't need to delivery local items more than once
(cherry picked from commit 139c39c2ce)
2018-06-08 08:38:53 +02:00
zotlabs
5e5b9895df when removing a connection, use the same rules as expire: don't remove items that are starred, filed, or that you replied to.
(cherry picked from commit 5d83469621)
2018-06-08 08:37:36 +02:00
zotlabs
ac8f798e56 don't show forums in forum widget if archived flag is set
(cherry picked from commit 7c05500392)
2018-06-08 08:37:13 +02:00
Manuel Jiménez Friaza
5c8ec5cce4 Initial translations in doc/es-es
(cherry picked from commit ea8ff7037a)
2018-06-08 08:36:19 +02:00
Mario Vavti
19e509d997 escape query string
(cherry picked from commit b3928f3d2a)
2018-06-08 08:33:38 +02:00
Mario Vavti
38b230a128 typo
(cherry picked from commit b47fdd748f)
2018-06-08 08:31:02 +02:00
Mario
5deecfea28 Merge branch 'master' into 'master'
Master

See merge request hubzilla/core!1211
2018-06-08 08:26:15 +02:00
gia vec
009ecb0ff4 Update developers.bb 2018-06-07 22:13:18 +02:00
gia vec
68ffddafb1 Update Developers.md 2018-06-07 22:10:32 +02:00
zotlabs
d3f741a8b6 update a number of links in the code
(cherry picked from commit 2c7597066c)
2018-06-07 14:19:31 +02:00
Mario Vavti
9d664df993 remove gravizot.de from directory fallback servers due to owners request 2018-06-06 22:14:10 +02:00
Mario Vavti
89ecc07eb0 update install instructions 2018-06-06 22:13:27 +02:00
Manuel Jiménez Friaza
4aa9549828 Some stuff of the Spanish Hubzilla 2018-05-29 08:52:49 +02:00
Mario Vavti
9655b27f81 fix js error with catalan language (unescaped strings) 2018-05-27 12:21:20 +02:00
git-marijus
13b3594ff3 Merge pull request #1191 from jeroenpraat/master
Finaly update of Dutch language strings
2018-05-25 12:37:11 +02:00
Jeroen
fb060c27ef Finaly update of Dutch language strings
Already in dev, but it's up to Mario or Mike to decide if the master may be updated too
2018-05-24 18:25:28 +02:00
git-marijus
2599d78d0c Merge pull request #1185 from antil0pa/patch-1
Update remote_friends_common.tpl
2018-05-24 11:49:35 +02:00
antil0pa
1da0042ee5 Update remote_friends_common.tpl
Found an improperly closed <div> tag. It breaks the way widget are displayed on the page.
2018-05-22 16:24:04 +02:00
Mario Vavti
4610fa2774 address globbing issue in #1170 2018-05-21 20:01:45 +02:00
Mario
5b48eb3657 update oauth related tables to use bigint/int(10) for user_id column. this is to be more consistent with the rest of the tables and fixes issue #1180 2018-05-20 22:55:13 +02:00
Mario Vavti
43f04e4bc0 improve abconfig queries 2018-05-20 22:55:01 +02:00
Mario Vavti
649260ce44 more local_channel() is not string 2018-05-20 22:54:49 +02:00
Mario Vavti
f091a3c9fc local_channel() is not string 2018-05-20 22:54:36 +02:00
Mario Vavti
18338495af do not update #acl-list-content on every click in jot. we just need this updated when in cutom mode (which is rarely the case). jot interaction was getting sluggish due to this when having lots of contacts. 2018-05-20 22:54:02 +02:00
Mario Vavti
a3f9cf7e97 update to fork-awesome 1.1 and fix an old font-awesome reference 2018-05-20 22:53:19 +02:00
Mario Vavti
ef0f195fe8 fix issue where images were not visible in acl selector after using search 2018-05-20 22:52:33 +02:00
git-marijus
23b53cd1ce Merge pull request #1178 from fadelkon/master
Update catalan translations
2018-05-20 11:44:59 +02:00
git-marijus
d0d14579d1 Merge pull request #1170 from waitman/master
shebang portable
2018-05-20 11:23:15 +02:00
fadelkon
8733d9f2a6 Update catalan translation (both po and php) for sources changes up to Apr 23rd 2018, 07:35. 2018-05-20 05:59:43 +02:00
fadelkon
29da06c298 Update view/ca/hstrings.php to match the version of view/ca/hmessages.po 2018-05-20 05:46:31 +02:00
zotlabs
da460ff32f anybody authenticated not correctly handled in can_comment_on_post() 2018-05-16 10:57:13 +02:00
root
1509c9682b replace disable globbing switch 2018-05-12 10:23:45 -07:00
root
e7287152a2 replace disable globbing switch 2018-05-12 10:22:01 -07:00
root
082bd58805 replace disable globbing switch 2018-05-12 10:18:13 -07:00
root
e288f46967 shebang portable 2018-05-12 09:58:19 -07:00
Mario Vavti
984de8f46f fix postgres issue if register mode is set to yes - with approval 2018-05-12 12:46:38 +02:00
zotlabs
6ad4ed87a3 yet another postgres/"group by" issue 2018-05-08 11:48:26 +02:00
Mario Vavti
be4c9a9598 Merge branch '3.4RC' 2018-05-04 09:46:27 +02:00
Mario Vavti
be852ba857 release version 3.4 2018-05-04 09:45:14 +02:00
Mario Vavti
3370e8516f switch DIRECTORY_FALLBACK_MASTER to https://zotadel.net 2018-05-04 09:43:01 +02:00
Mario Vavti
108cc7b270 update changelog 2018-05-04 09:35:22 +02:00
Mario Vavti
94316da63e RC5 2018-05-03 13:38:54 +02:00
Mario Vavti
2f9a044559 Revert "hubzilla issue #1151 - activitypub mention gets bookmarked"
This reverts commit 285781b887.
2018-05-03 12:34:51 +02:00
zotlabs
1f429a0033 hubzilla issue #1151 - activitypub mention gets bookmarked 2018-05-03 12:34:35 +02:00
zotlabs
a3ed0b94cd make the cloud logging a bit less verbose until we actually need it. 2018-05-03 12:33:48 +02:00
Mario Vavti
dd806bd031 update composer autoload cache 2018-05-03 12:27:39 +02:00
Mario Vavti
40db68886d RC4 2018-05-02 10:11:05 +02:00
Galette Saucisse
d5088549f8 Create /doc/context/fr/wiki/help.html 2018-05-02 09:49:02 +02:00
Galette Saucisse
03851ee7cc Create /doc/context/fr/webpages/help.html 2018-05-02 09:48:40 +02:00
Galette Saucisse
2d460117fc Create /doc/context/fr/settings/tokens 2018-05-02 09:48:30 +02:00
Galette Saucisse
73cabbf822 Create /doc/context/fr/settings/channel/help.html 2018-05-02 09:48:19 +02:00
Galette Saucisse
411b7964ab Create /doc/context/fr/settings/account/help.html 2018-05-02 09:48:09 +02:00
Galette Saucisse
bc45c5368e Create /doc/context/fr/profile/help.html 2018-05-02 09:47:50 +02:00
Galette Saucisse
7a65b6cfe4 Create /doc/context/photos/help.html 2018-05-02 09:47:39 +02:00
Galette Saucisse
ee464c6589 Create /doc/context/fr/mail/help.html 2018-05-02 09:47:30 +02:00
zotlabs
a9b71f5b4a The channel import page seems to have missed the big theme cleanup of the last couple of years. 2018-05-02 09:30:45 +02:00
zotlabs
c99fb4b7f1 provide warnings about profile photo and cover photo permissions 2018-05-02 09:30:33 +02:00
zotlabs
b28279241b hubzilla issue #1149, don't duplicate addressbook entries on repeated channel imports 2018-05-02 09:30:23 +02:00
Mario Vavti
5c5ae2969e Revert "Revert "hubzilla issue #1119 - xml2array has issues with some unicode sequences/conversions. Working around it using the older simplexml parser until it can be debugged, as Diaspora does not use complex XML with namespaces; which is where we need the more advaced capabilities of xml2array.""
This reverts commit b223e364c6.
2018-05-02 09:30:05 +02:00
zotlabs
3af691043d parent folder permissions weren't being checked back to the cloud root directory in all cases 2018-05-02 09:29:52 +02:00
Mario Vavti
12c9e64463 activitypub xchans do not have an xchan_addr. use xchan_url for the follow button if we do not find an xchan_addr 2018-04-30 14:34:25 +02:00
Mario
875597cde1 fix another pgsql update error 2018-04-30 11:51:14 +02:00
Mario
f15c12376a Merge branch 'master' of https://github.com/redmatrix/hubzilla 2018-04-30 11:34:10 +02:00
Mario Vavti
e1738e8021 Revert "hubzilla issue #1119 - xml2array has issues with some unicode sequences/conversions. Working around it using the older simplexml parser until it can be debugged, as Diaspora does not use complex XML with namespaces; which is where we need the more advaced capabilities of xml2array."
This reverts commit f620274c6a.
2018-04-30 10:27:11 +02:00
Galette Saucisse
a33dfff188 Create /doc/context/fr/events/help.html 2018-04-30 09:59:22 +02:00
Galette Saucisse
f897cd6bc8 Create /doc/context/fr/connedit/help.html 2018-04-30 09:58:10 +02:00
Galette Saucisse
dfce7c6ca4 Create /doc/context/fr/connections/ifpending/help.html 2018-04-30 09:56:34 +02:00
Galette Saucisse
eabed9d0e5 Create /doc/context/fr/connections/help.html 2018-04-30 09:55:45 +02:00
Galette Saucisse
0992822ce5 Create /doc/context/fr/cloud/help.html 2018-04-30 09:54:57 +02:00
HappyPony
472ed909cd Russian translation for cards 2018-04-30 09:54:01 +02:00
Galette Saucisse
a60b91b21e Create /doc/context/fr/chat/help.html 2018-04-30 09:53:17 +02:00
Galette Saucisse
02459ebde0 Create /doc/context/fr/cards/help.html 2018-04-30 09:52:47 +02:00
Galette Saucisse
7bb69e20f5 Create /doc/context/fr/apps/edit/help.html 2018-04-30 09:51:43 +02:00
Galette Saucisse
5dd291fc60 Create /doc/context/fr/appman/help.html 2018-04-30 09:50:49 +02:00
Galette Saucisse
630ccf3810 Create /doc/context/fr/appman/help.html 2018-04-30 09:50:47 +02:00
Galette Saucisse
05c137c1ab Create /doc/context/fr/apps/help.html 2018-04-30 09:48:31 +02:00
Mario Vavti
a48e795f8a missing class 2018-04-30 09:14:57 +02:00
zotlabs
f620274c6a hubzilla issue #1119 - xml2array has issues with some unicode sequences/conversions. Working around it using the older simplexml parser until it can be debugged, as Diaspora does not use complex XML with namespaces; which is where we need the more advaced capabilities of xml2array. 2018-04-30 09:14:46 +02:00
zotlabs
ae5b3a83f1 Update issues on postgres 2018-04-30 09:14:32 +02:00
zotlabs
5e23640563 remove unused function 2018-04-30 09:14:22 +02:00
zotlabs
94df121e0a sql error 2018-04-27 14:27:10 +02:00
Mario Vavti
31e9efdae0 RC3 2018-04-27 10:14:04 +02:00
phellmes
bb2103ac45 Update DE translation strings
German strings for development branch and release candidate 3.4
2018-04-27 10:07:25 +02:00
Galette Saucisse
feb03dc194 Update FR toc.html 2018-04-27 10:06:46 +02:00
Galette Saucisse
02da3adb5a Delete FR project.bb from wrong folder
apologies
2018-04-27 10:05:54 +02:00
Galette Saucisse
051ab698ed Update project.bb 2018-04-27 10:04:00 +02:00
Galette Saucisse
9014524477 Update project.bb and place in correct folder
FR toc.html needs editing
2018-04-27 10:03:55 +02:00
mjfriaza
9387be1aa7 New strings: Spanish translation 2018-04-27 10:00:50 +02:00
zotlabs
d0ba2cf6d4 where possible strip zid parameter from links that get pasted into posts so that they will get a correct zid when rendered 2018-04-27 09:58:17 +02:00
zotlabs
e33d8c288b more testing of attach_move() uncovered some issues 2018-04-27 09:58:07 +02:00
zotlabs
34fbcfdfaa set the 'force' flag on attach_mkdir when initiated from a DAV operation. This will report success if it already exists rather than throwing an exception. 2018-04-27 09:57:57 +02:00
Mario Vavti
a85b1efa4f minor fixes for dark schema 2018-04-26 22:46:01 +02:00
zotlabs
a5a6488757 don't load jot autosave content into other document types or edits of other items, but do save these edits in case you need to recover them 2018-04-26 09:58:56 +02:00
zotlabs
b8aabde6c3 malformed embeds from gfycat hubzilla issue #1108 2018-04-26 09:42:54 +02:00
zotlabs
44d4f0a484 generating random numbers too large for 32-bit systems 2018-04-26 09:41:26 +02:00
Mike Macgirvin
a124c120f4 Update CHANGELOG
more than oauth2
2018-04-26 13:20:24 +10:00
Mario Vavti
7283e2e279 bump version 2018-04-25 14:18:17 +02:00
Mario Vavti
352dd364d2 drop box-shadow from generic-content-wrapper (it's probably too 90') and use transparent colors for borders to work better with alternate background colors 2018-04-25 14:17:53 +02:00
Mario Vavti
fe318d4eb8 changelog 2018-04-25 12:48:53 +02:00
Mario Vavti
ebf540ffbc rename boxy schema to focus-boxy and bs-default to focus-light 2018-04-25 11:36:22 +02:00
Mario Vavti
4f1031f92b mark simple_* schemas unmaintained and deprecated 2018-04-25 11:36:10 +02:00
Mario Vavti
705ff97892 more css fixes for bs-default schema 2018-04-25 11:02:52 +02:00
Mario Vavti
da775d182a css fixes for bs-default schema 2018-04-25 10:58:08 +02:00
Galette Saucisse
0f836c9d5e Create /doc/fr/project.bb 2018-04-25 10:34:16 +02:00
Mario Vavti
25f34d8ad3 show caret-down on item-photo hover to indicate a dropdown menu 2018-04-25 09:56:53 +02:00
Mario Vavti
edd91a7ed1 changelog 2018-04-24 22:30:52 +02:00
Mario Vavti
4bb93c4327 fix regression with forum widget unseen count 2018-04-24 17:11:29 +02:00
Mario Vavti
2dce7c212f fix php warnings 2018-04-24 15:42:20 +02:00
Mario Vavti
d401e5e7c4 possible fix for issue #1101 2018-04-23 21:12:31 +02:00
Mario Vavti
67ce5f4c9c version 3.4RC1 2018-04-23 12:05:06 +02:00
Mario Vavti
5bd1ea0b95 Merge branch 'dev' into 3.4RC 2018-04-23 11:52:32 +02:00
Mario Vavti
9ac67b44e4 strings update 2018-04-23 11:37:39 +02:00
Mario Vavti
bc4a1ee500 reverse f325c29b48 - this needs discussion. there is a link to source in the item menu. we might consider linking the timestamp to the source item (like some of the federated networks do) but then remove it from the item dropdown (having things double proved to confuse people). imo the link in the dropdown menu should be sufficient though. 2018-04-23 11:24:13 +02:00
git-marijus
78816f2f74 Merge pull request #1094 from mrjive/dev
Adding link to post source
2018-04-23 11:11:16 +02:00
Mario Vavti
fedb5fbcf5 update zot.php to fix php warning invalid argument supplied for foreach()
- this is taken from pr #1085 which was against wrong branch
2018-04-23 10:47:35 +02:00
Mario Vavti
bb61e672b0 Proposed fix for issue #1091 - mod-help.css
- this is taken from pr #1098 which was against wrong branch
2018-04-23 10:39:46 +02:00
git-marijus
de6f07ec89 Merge pull request #1097 from galettesaucisse/patch-13
Proposed fix for issue #1091 - mod-help.js
2018-04-23 10:28:50 +02:00
git-marijus
d0dc8c1e4c Merge pull request #1093 from mjfriaza/dev
Updated Spanish translation
2018-04-23 10:28:09 +02:00
git-marijus
5ec2e28802 Merge pull request #1090 from galettesaucisse/patch-12
Create /doc/fr/toc.html
2018-04-23 10:27:50 +02:00
git-marijus
391020fd1b Merge pull request #1089 from galettesaucisse/patch-11
delete /doc/fr/about.bb
2018-04-23 10:27:31 +02:00
git-marijus
e46874149d Merge pull request #1088 from galettesaucisse/patch-10
create new file /doc/fr/about/about.bb
2018-04-23 10:27:04 +02:00
git-marijus
7f49f6a45c Merge pull request #1084 from galettesaucisse/patch-9
Update French hmessages.po from Transifex
2018-04-23 10:26:42 +02:00
git-marijus
901b0ac146 Merge pull request #1083 from galettesaucisse/patch-8
Update French hstrings.php from Transifex
2018-04-23 10:26:12 +02:00
Mario Vavti
28bc4089d0 fix permission role test 2018-04-23 10:03:39 +02:00
Mario Vavti
2bca612a92 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into dev 2018-04-23 09:49:47 +02:00
zotlabs
66d72d9870 as_fetch depends on the pubcrawl plugin, but is referenced in core. Ensure that it doesn't chuck a wobbly if the function isn't found. This is undergoing significant revision for zot6 so this action is considered a short-term workaround until that work work stabilises. 2018-04-22 22:10:15 -07:00
zotlabs
11624cd83e owa: attempt channel discovery if not found 2018-04-22 19:24:15 -07:00
zotlabs
55b7182136 use consistent naming for 'Channel role and privacy' 2018-04-22 18:48:48 -07:00
zotlabs
55dc6fbc1c imagemagick preserves exif when scaling. GD does not. We do not want to preserve exif on thumbnails which we have rotated, as a browser reading the exif information could rotate them yet again. This checkin adds an abstract function to the generic photo driver which makes the behaviour consistent by stripping EXIF from imagick processed images. However, we will attempt to preserve any ICC colour profiles. See http://php.net/manual/en/imagick.stripimage.php 2018-04-22 18:12:16 -07:00
Jeroen
c446ffb814 back to only nickname 2018-04-22 20:16:04 +02:00
Jeroen
689ced2ac0 back to only nickname 2018-04-22 20:15:14 +02:00
mrjive
51c533536f Merge pull request #10 from redmatrix/dev
Dev
2018-04-22 10:54:41 +02:00
Mike Macgirvin
2431631b46 Update PermissionLimits.php
anon comment permissions fix
2018-04-22 07:00:01 +10:00
Mike Macgirvin
e189f5f887 Update PermissionLimits.php
Difficult for me to do this locally at the moment so updating in git
2018-04-22 06:58:33 +10:00
Mike Macgirvin
5a736d338b Merge pull request #1099 from zotlabs/dev
This is important
2018-04-21 19:09:27 +10:00
zotlabs
95059f2bfd fix permissionlimitstest after recent changes 2018-04-21 00:37:04 -07:00
zotlabs
1bb67f63e3 anonymous comments shouldn't be allowed in StdLimits 2018-04-20 18:58:21 -07:00
zotlabs
b12d254427 fix any misconfigured channel permission limits 2018-04-20 18:58:21 -07:00
zotlabs
af909f66a7 fix any misconfigured channel permission limits 2018-04-20 15:03:16 -07:00
zotlabs
e05f41630b anonymous comments shouldn't be allowed in StdLimits 2018-04-20 14:38:15 -07:00
Galette Saucisse
ba8f8c3403 Proposed fix for issue #1091 2018-04-20 19:17:52 +02:00
mrjive
84e2bdcf76 updated Italian translation 2018-04-20 06:25:40 -07:00
Manuel Jiménez Friaza
a211c16b73 Updated Spanish translation 2018-04-20 11:36:13 +02:00
mrjive
f325c29b48 adding link to post source 2018-04-20 02:29:57 -07:00
zotlabs
d5c451c4a8 This fix needs to go deeper in the code. PermissionLimits::Get is called in a lot of places. If we have no stored setting for a particular permission, return 0 - which is basically no permission except to self. 2018-04-19 23:44:22 -07:00
zotlabs
8d0cbeab38 better fix to permisisons.php - just cast to int. That's exactly what we want. 2018-04-19 23:37:47 -07:00
zotlabs
636fb95e24 permissions php error applying bit compare operation on a (presumed) boolean 2018-04-19 23:35:24 -07:00
zotlabs
2f1ad15645 fix navbar contact autocomplete 'undefined' hovertip 2018-04-19 22:19:52 -07:00
zotlabs
b1ed79f239 fix link to renamed permission roles doc subsection 2018-04-19 19:32:48 -07:00
zotlabs
aea61bf034 rename social - party to social - federation. Cleanup some of the documentation surrounding channels. This checkin contains translatable string changes. 2018-04-19 19:05:13 -07:00
zotlabs
2254262cf0 code booboo may have degraded the performance of the Trending tag query more than necessary 2018-04-19 17:43:50 -07:00
Galette Saucisse
872e4a0513 Create /doc/fr/toc.html
please add translated file toc.html
2018-04-19 18:22:47 +02:00
Galette Saucisse
0e1ea54c32 Update about.bb 2018-04-19 15:30:48 +02:00
Galette Saucisse
ff69413729 delete /doc/fr/about.bb
file is in wrong place, and supersceded by /doc/fr/about/about.bb
2018-04-19 15:11:49 +02:00
Galette Saucisse
a8c2b75b9b create new folder and file about.bb
the current about.bb is under /doc/fr/ and should be under /doc/fr/about/
this file is a complete French translation of the original English file
2018-04-19 15:07:28 +02:00
mrjive
c8ff773b96 Merge pull request #9 from redmatrix/dev
Dev
2018-04-19 09:51:58 +02:00
zotlabs
fa78dc79f3 follow activitypub by webfinger; requires addon update to all federation protocols 2018-04-19 08:44:41 +02:00
zotlabs
1ef31d27c7 relax restrictions to the design tools menu to allow those with write_pages permission; this doesn't fix the underlying modules though as there are some potential security issues at the moment. 2018-04-19 08:44:17 +02:00
zotlabs
f634d15768 do not queue anything which lacks a destination url 2018-04-19 08:42:50 +02:00
zotlabs
9bc9aa123f just provide the trending tags in public stream by default and simplify the query to improve load times; I intend to do additional work on this feature later 2018-04-19 08:42:37 +02:00
Mario Vavti
92b08f1f07 Merge remote-tracking branch 'mike/master' into dev 2018-04-19 08:28:42 +02:00
zotlabs
a81011333f follow activitypub by webfinger; requires addon update to all federation protocols 2018-04-18 19:41:09 -07:00
zotlabs
a2e0706d55 relax restrictions to the design tools menu to allow those with write_pages permission; this doesn't fix the underlying modules though as there are some potential security issues at the moment. 2018-04-18 17:26:05 -07:00
zotlabs
85ccfb4bbc do not queue anything which lacks a destination url 2018-04-18 17:07:29 -07:00
zotlabs
2ec28a5993 just provide the trending tags in public stream by default and simplify the query to improve load times; I intend to do additional work on this feature later 2018-04-18 15:56:57 -07:00
Galette Saucisse
8ff8a3eab9 Update French hmessages.po from Transifex 2018-04-18 17:41:09 +02:00
Galette Saucisse
f5573deb60 Update French hstrings.php from Transifex 2018-04-18 17:39:20 +02:00
Mario Vavti
16dcbc1e67 bump version 2018-04-18 08:52:10 +02:00
Mario Vavti
19782655e6 version bump and strings 2018-04-18 08:39:43 +02:00
zotlabs
c53f788cc8 add alt_pager to mod_moderate, remove legacy $a parameter from all occurrences of alt_pager 2018-04-17 23:36:35 -07:00
Mario Vavti
440ccf19d1 Merge remote-tracking branch 'mike/master' into dev 2018-04-18 08:19:56 +02:00
zotlabs
fc7d9c235c minor code optimisation 2018-04-17 22:23:28 -07:00
zotlabs
0f5ae5cac8 also add the noisy 'rss' tag 2018-04-17 21:55:00 -07:00
zotlabs
6903dbcc0d re-use directory safemode setting for public stream tag filtering since a handful of well-known tags skews the results wildly. Added 'bot' to the list just because it's noisy. A site can customise or nullify this feature if they desire. 2018-04-17 21:48:43 -07:00
zotlabs
a806c68713 fine tuning the public stream tag results 2018-04-17 20:27:36 -07:00
zotlabs
393cd46a82 public stream tag enhancements 2018-04-17 20:08:14 -07:00
zotlabs
0576046d02 when changing cover photo, show existing 2018-04-17 16:29:32 -07:00
Mario Vavti
c0794a83b4 Merge remote-tracking branch 'mike/master' into dev 2018-04-17 19:00:15 +02:00
Mario Vavti
dcd636f7be fix closing parenthesis in wrong spot 2018-04-17 18:56:33 +02:00
Mario Vavti
83e7d89f7e update to bootstrap-4.1 and improve visibility of some text when using custom panel colours 2018-04-17 16:17:44 +02:00
zotlabs
02763811b3 missing update file in the previous update commit 2018-04-16 23:34:47 -07:00
zotlabs
8b9952e770 set the correct webfinger Accept: request header now that Mastodon fixed the bug that we changed it to work around 2018-04-16 23:32:40 -07:00
zotlabs
43e55eb9a6 Active channels information is a bit imprecise. Provide a higher accuracy method. This will require a transition period 2018-04-16 21:40:43 -07:00
zotlabs
120e578a67 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-04-16 20:28:22 -07:00
zotlabs
411b8e48a3 don't save a permcat with empty name 2018-04-16 18:09:14 -07:00
zotlabs
d38b5ed2f5 update the placeholder 2018-04-16 17:40:33 -07:00
zotlabs
04abfdd5a6 update the search js 2018-04-16 17:37:38 -07:00
zotlabs
1662f76f03 hubzilla issue #1078 ; provide content-type header for system emails (was already correct for notification emails) 2018-04-16 16:12:57 -07:00
mrjive
283e5d3a5c Merge pull request #8 from redmatrix/dev
Dev
2018-04-16 17:27:14 +02:00
Mario Vavti
bef5be827d remove some more distinct in queries and observe any regressions. this is related to issue #1079 and commit d47ea20aa8 2018-04-16 11:42:13 +02:00
Mario Vavti
a8b78dc1f5 Merge remote-tracking branch 'mike/master' into dev 2018-04-16 09:24:22 +02:00
zotlabs
19888b95cc draft-cavage issues 2018-04-15 21:04:09 -07:00
zotlabs
3e6a55a295 issue with wiki sync 2018-04-15 17:29:40 -07:00
Mario Vavti
bbe58dd550 css fixes 2018-04-15 10:20:32 +02:00
Mario Vavti
a422063c7d fix regression where in the starred tab only top level posts were visible 2018-04-15 10:15:49 +02:00
zotlabs
518db97962 never mind. dbg(1) now gives you the basic debug result and dbg(2) gives you the verbose debug option with all the results. 2018-04-14 16:56:30 -07:00
zotlabs
fdf5799857 allow dbg(2) to only return the canonical SQL used in the query and the number of results, but not log every single result. Maybe we should use 1 for this and 2 for the full results, but I didn't really want to change the way people do things today. If anybody has a strong opinion about doing this, go ahead and change it and send a note to the developer forum. 2018-04-14 16:47:51 -07:00
mrjive
99dc161483 Merge pull request #7 from redmatrix/dev
Dev
2018-04-14 15:59:30 +02:00
zotlabs
f16dc7afc8 upgrade incutio xmlrpc library to use hubzilla curl wrapper 2018-04-13 17:58:11 -07:00
Galette Saucisse
32cd0cc984 Create /doc/context/fr/settings/features/help.html
French translation for context help
2018-04-13 22:17:48 +02:00
Galette Saucisse
169d75d2d1 Update hstrings.php 2018-04-13 22:17:37 +02:00
Galette Saucisse
6d234daa88 Update hmessages.po 2018-04-13 22:17:27 +02:00
Galette Saucisse
f8f64e853d Create /doc/context/fr/admin/queue/help.html
French translation for context help
2018-04-13 22:17:11 +02:00
Galette Saucisse
823b873e50 Update help.html 2018-04-13 22:16:53 +02:00
Galette Saucisse
5c97280359 translation correction 2018-04-13 22:16:41 +02:00
Galette Saucisse
7e62c3fa29 Create /doc/context/fr/admin/logs/help.html
French translation of context help
2018-04-13 22:16:10 +02:00
Galette Saucisse
c18b6cbd68 Create /doc/context/fr/channel
French translation for context help
2018-04-13 22:15:58 +02:00
git-marijus
29b3950e32 Merge pull request #1067 from galettesaucisse/patch-7
Create /doc/context/fr/settings/features/help.html
2018-04-13 22:14:15 +02:00
git-marijus
17bc11bbd4 Merge pull request #1066 from galettesaucisse/patch-6
Update French hstrings.php
2018-04-13 22:13:33 +02:00
git-marijus
3e937266b2 Merge pull request #1063 from galettesaucisse/patch-5
Update French hmessages.po
2018-04-13 22:13:13 +02:00
git-marijus
a02f22aab7 Merge pull request #1060 from galettesaucisse/patch-4
Create /doc/context/fr/admin/queue/help.html
2018-04-13 22:12:51 +02:00
git-marijus
b31616e5bf Merge pull request #1059 from galettesaucisse/patch-3
Create /doc/context/fr/admin/logs/help.html
2018-04-13 22:12:22 +02:00
git-marijus
b1057e8cd1 Merge pull request #1056 from galettesaucisse/patch-2
Create /doc/context/fr/channel
2018-04-13 22:12:03 +02:00
Mario Vavti
7543e27eae version and strings update 2018-04-13 22:11:08 +02:00
Mario Vavti
8a43bead74 fix illegal string offset warning 2018-04-13 13:20:20 +02:00
Mario Vavti
2867cd2043 fix wrong item key 2018-04-13 12:50:37 +02:00
Mario Vavti
88ca6fc12e Merge remote-tracking branch 'mike/master' into dev 2018-04-13 11:59:09 +02:00
Mario Vavti
e04d3c45a4 provide visible star status for starred posts 2018-04-13 11:58:12 +02:00
mrjive
db586e0c27 Merge pull request #6 from redmatrix/dev
Dev
2018-04-13 10:23:30 +02:00
Mario Vavti
4aaea422bc move the thread author menu to to the wall item photo. the menu list was getting too long. 2018-04-13 10:12:57 +02:00
zotlabs
7fd882a088 autosave comment enhancements 2018-04-12 22:24:25 -07:00
zotlabs
b0396cd646 work on autosave 2018-04-12 21:44:06 -07:00
zotlabs
d5117a62b8 update the tags and mentions section of the member_guide with recent changes 2018-04-12 20:49:20 -07:00
zotlabs
b13328140f accept system_language through either get or post 2018-04-12 18:21:34 -07:00
zotlabs
3be0b0925c remove recipient name from stored notifications but keep them in emails. 2018-04-12 17:55:45 -07:00
Mario Vavti
7c47b9d75c Merge remote-tracking branch 'mike/master' into dev 2018-04-12 14:46:36 +02:00
Mario Vavti
09a8b4b379 fix issue #1047 2018-04-12 10:58:31 +02:00
mrjive
ea36ebd0df Merge pull request #5 from redmatrix/dev
Dev
2018-04-12 10:12:46 +02:00
zotlabs
549f7a53b1 util/dcp (server to cloud file copy) better handling when destination directory is the channel root 2018-04-11 22:27:59 -07:00
zotlabs
739a612824 poll responses: start treating them as hidden activities now so that when this feature gets finished it will work flawlessly for versions greater than today. 2018-04-11 21:51:57 -07:00
zotlabs
953a2fd9b2 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-04-11 17:44:51 -07:00
zotlabs
2fa9645dfc channel delegation: push current identity and pop it on logout from the delegated channel. This fixes the known issue of being forced to log back in after leaving the delegated channel. 2018-04-11 17:40:04 -07:00
Mario Vavti
3bd6450333 also clean localStorage upon logout or channel switch 2018-04-11 12:37:25 +02:00
Mario Vavti
fee258edbe allow to toggle visibility of likes/dislikes in notifications 2018-04-11 11:49:33 +02:00
Mario Vavti
e294dfa760 wrong function 2018-04-11 08:17:30 +02:00
Galette Saucisse
669013f7e6 Create /doc/context/fr/settings/features/help.html
French translation for context help
2018-04-10 19:59:09 +02:00
Galette Saucisse
dde482082e Update hstrings.php 2018-04-10 19:10:11 +02:00
Galette Saucisse
868e9aa058 Update hmessages.po 2018-04-10 18:02:42 +02:00
Galette Saucisse
a815e2e30b Create /doc/context/fr/admin/queue/help.html
French translation for context help
2018-04-10 14:08:26 +02:00
Galette Saucisse
89b76530da Update help.html 2018-04-10 14:06:10 +02:00
Galette Saucisse
e909c2bbce translation correction 2018-04-10 14:05:31 +02:00
Galette Saucisse
ab1e1e9114 Create /doc/context/fr/admin/logs/help.html
French translation of context help
2018-04-10 13:36:38 +02:00
Galette Saucisse
13b0fdadb1 Create /doc/context/fr/channel
French translation for context help
2018-04-10 12:19:29 +02:00
Galette Saucisse
90580a860b Update French hstrings.php
added some missing strings
2018-04-10 12:11:15 +02:00
git-marijus
6d7fdb14f0 Merge pull request #1054 from galettesaucisse/patch-1
Update French hstrings.php
2018-04-10 12:10:45 +02:00
Mario Vavti
a2cb7b9ca4 do not get or set post category if the field is not available. remove logging. 2018-04-10 11:37:57 +02:00
Mario Vavti
91aeb25523 fix autosave content not cleaned after post submission 2018-04-10 11:17:20 +02:00
Galette Saucisse
bb86ee7cc4 Update French hstrings.php
added some missing strings
2018-04-10 09:54:26 +02:00
zotlabs
887a59066b last commented expiration setting in admin 2018-04-10 00:05:20 -07:00
zotlabs
e060135304 add commented_days parameter to item_expire(), default 7. Both expire_days and commented_days have to be exceeded to expire. 2018-04-09 23:39:47 -07:00
zotlabs
6bf2c64aa2 Create catcloud widget and provide a type option which can include 'cards' or 'articles' 2018-04-09 21:44:04 -07:00
Andrew Manning
1aba495a1c Replace pushState with replaceState to prevent browser history clutter in Help pages. 2018-04-09 20:50:41 -04:00
git-marijus
482e26ae26 Merge pull request #1053 from jschweinsberg/fix/pubstream-notifications
Public stream notifications
2018-04-09 22:41:40 +02:00
Julian Schweinsberg
c50105b8c1 Show "Unseen public activity" channel setting when site only public streams are activated 2018-04-09 19:26:35 +02:00
Julian Schweinsberg
530a378aa1 Modified notifications widget to add the public stream when the current user is allowed to see it only 2018-04-09 19:18:53 +02:00
Mario Vavti
04935f139d fix xchan_query() for anon comments 2018-04-09 14:28:41 +02:00
Mario Vavti
5228462363 bump version 2018-04-09 13:19:22 +02:00
git-marijus
9dc831f1ef Merge pull request #1051 from anaqreon/auto-save
Auto-save comment and post text
2018-04-09 13:18:09 +02:00
zotlabs
6844d7c752 don't provide a connect button for transient identities 2018-04-08 22:53:04 -07:00
zotlabs
cda3d23508 more intelligent handling of level 0 - and remove an extraneous logging function 2018-04-08 22:09:08 -07:00
zotlabs
e4ee165e29 more work merging techlevels and features 2018-04-08 22:02:48 -07:00
zotlabs
e0255c0dc4 first cut of feature/techlevel merge 2018-04-08 20:05:30 -07:00
zotlabs
6ce3ca1ce0 anon_identity_init: put anonymous commenters in network 'anon' so that they can be easily distinguished from federated network members and handled appropriately. 2018-04-08 19:28:57 -07:00
zotlabs
c3cd613f42 extend AC 2018-04-08 17:30:46 -07:00
zotlabs
f2078b25ad hubzilla issue #1050 pubstream notifications visible when pubstream is not 2018-04-08 16:51:29 -07:00
Andrew Manning
f9ec3c66ff Added feature setting for auto-save, defaulting to enabled. 2018-04-08 19:44:21 -04:00
Andrew Manning
4760dc9bcb removed Autosavetext.php file since it is not used with localStorage 2018-04-08 14:25:04 -04:00
Andrew Manning
808f362921 Merge branch 'dev' into auto-save 2018-04-08 14:23:34 -04:00
Andrew Manning
43cafcc761 Auto-save post and comment entry using localStorage in browser. 2018-04-08 14:18:10 -04:00
zotlabs
b00c22b69b we shouldn't need distinct here, since ids_to_querystr() will filter duplicates. It might have an effect on pager totals. Need to monitor for a few days. 2018-04-08 12:55:52 +02:00
git-marijus
73248fd227 Merge pull request #1048 from dentm42/plugin-error-trap
Trap plugin install/uninstall load/unload errors to avoid whitescreen
2018-04-08 11:48:05 +02:00
Mario Vavti
7205ffb5c0 Merge remote-tracking branch 'mike/master' into dev 2018-04-08 11:38:31 +02:00
M.Dent
ff77f14f2f Remove remove plugin from \App::[] on uninstall 2018-04-07 23:41:22 -04:00
M.Dent
a0cba6564f Uninstall plugin on Exception on load. 2018-04-07 23:12:39 -04:00
M.Dent
35b4f0a863 Add class for Exceptions 2018-04-07 23:01:18 -04:00
DM42.Net (Matt Dent)
0fba1a777e Add error handler and try/catch for all () calls 2018-04-07 22:17:19 -04:00
zotlabs
d47ea20aa8 we shouldn't need distinct here, since ids_to_querystr() will filter duplicates. It might have an effect on pager totals. Need to monitor for a few days. 2018-04-07 16:54:49 -07:00
Andrew Manning
be6dcb5d0a Merge branch 'dev' into auto-save 2018-04-07 17:48:48 -04:00
Mario Vavti
bddf8cfde4 Merge remote-tracking branch 'mike/master' into dev 2018-04-07 14:16:59 +02:00
Mario Vavti
9369150db7 rename button label in editpost from edit to submit 2018-04-07 14:15:07 +02:00
Mario Vavti
0fd7634339 rename relation to relationship - issue #1044 2018-04-07 13:50:41 +02:00
Mario Vavti
969a91c432 use Title instead of Caption - issue #1037 2018-04-07 13:36:34 +02:00
Mario Vavti
4d08fcf1a7 Use Add Files/Photos instead of Upload to open the upload dialog 2018-04-07 13:29:36 +02:00
zotlabs
8048b7addc channel import failing to provide channel_password value 2018-04-06 16:45:25 -07:00
zotlabs
4499ee178f put directory server in siteinfo - there are a lot of sites using broken directories 2018-04-06 01:24:38 -07:00
zotlabs
b17f741050 bring back the dnt policy document, not sure when it was lost 2018-04-05 22:15:15 -07:00
zotlabs
4a45c35c4e oauth2 client settings page 2018-04-05 21:01:36 -07:00
zotlabs
f4c94ab121 use profile_store_lowlevel() when importing profile structures to ensure all non-null fields are present 2018-04-05 17:31:20 -07:00
zotlabs
64bb1ca2bb Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-04-05 17:18:34 -07:00
zotlabs
b7386a0e88 fix permalinks to children of articles and cards 2018-04-05 16:58:37 -07:00
mrjive
a7ff2cc5ea Merge pull request #3 from redmatrix/dev
Dev
2018-04-05 10:52:39 +02:00
Mario Vavti
dcacdd23c8 Merge remote-tracking branch 'mike/master' into dev 2018-04-05 10:44:00 +02:00
Mario Vavti
8e46b07268 bump version 2018-04-05 10:31:51 +02:00
Mario Vavti
2f4c441074 change hearts for heart in reactions but cheet with the unicode 2018-04-05 10:11:02 +02:00
Mario Vavti
61f85bcb14 use transform to scale emojis. this prevents text jumping on hover 2018-04-05 10:10:26 +02:00
Mario Vavti
699ff644ad fix missing login/out buttons for medium screensize 2018-04-05 09:36:32 +02:00
zotlabs
0877e5b578 wrong function 2018-04-05 09:36:16 +02:00
zotlabs
46114bb24d display and link issues with quoted tags 2018-04-05 09:35:29 +02:00
zotlabs
6208ee3809 don't include the q and PHPSESSID request variables in a redirected rpost 2018-04-05 09:34:09 +02:00
zotlabs
17e341d245 php strpos() empty needle warning when a term entry has no url 2018-04-05 09:33:17 +02:00
zotlabs
f22c7afc59 preserve existing categories when updating an app from an embed source 2018-04-05 09:32:51 +02:00
zotlabs
d7aa24fd2d app sellpage not being stored 2018-04-05 09:32:35 +02:00
Mario Vavti
255c5ae94f new markdown lib seems to handle < and > correct. remove the workaraound. 2018-04-05 09:31:30 +02:00
zotlabs
ab2ff4a520 tagadelic was being overly protective of permissions. 2018-04-05 09:31:00 +02:00
zotlabs
1a53a4bc53 make list mode work in cards and articles 2018-04-05 09:30:01 +02:00
zotlabs
4423f4c930 make alt_pager work for articles/cards 2018-04-05 09:29:51 +02:00
zotlabs
9c512bb645 hubzilla issue #1013 - comments not displayed in single card/article view 2018-04-05 09:28:05 +02:00
git-marijus
bd0959b5a4 Merge pull request #1039 from phellmes/doco-feat-add
add basic structure for additional features documentation
2018-04-05 09:18:15 +02:00
zotlabs
fe401203bd bbcode() - ensure that $options is always an array, as the interface has changed slightly 2018-04-04 23:14:41 -07:00
zotlabs
c86032d4dc oauth2 dynamic client registration update 2018-04-04 20:58:54 -07:00
zotlabs
e864679942 private forum mentions 2018-04-04 18:53:06 -07:00
zotlabs
cadef5924f Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-04-04 18:15:33 -07:00
zotlabs
1a25b0bda7 allow the profile recrods to be cloned separately 2018-04-04 17:54:43 -07:00
zotlabs
f748139606 allow the link target attribute to be modified in bbcode() from much further up the call stack in prepare_page() which will usually refer to a local item. 2018-04-04 16:33:11 -07:00
Andrew Manning
a5aff7d0c9 Post body and title are auto-saved 2018-04-04 15:22:38 -04:00
phellmes
2afe28785c add basic structure for additional features documentation
Setting the raw frame with overview, short descriptions like in code
and already revealing skill levels.

Based on the current (recently modified) structure of the feature settings.

Detailed descriptions in work and coming with later commits as well as
a dedicated admin section for that topic. Better menu integration
may be possible with Andrew's new doco structure work in progress later.
2018-04-04 16:00:34 +02:00
Mario Vavti
aca719ac74 do not use punify() in get_baseurl() due to performance issues 2018-04-04 15:01:16 +02:00
zotlabs
8871f8d0f4 disable the oauth2testvehicle completely until it is safe 2018-04-03 21:58:11 -07:00
zotlabs
29b377d4c5 get rid of dangerous test code 2018-04-03 21:13:26 -07:00
zotlabs
4915a4efbb OAuth2 integration 2018-04-03 21:08:40 -07:00
zotlabs
245142cc07 Merge branch 'master' into oauth2 2018-04-03 19:57:35 -07:00
zotlabs
5ac0f371c7 community tags: allow signature of either author or owner so that it stands a chance of working across multiple delivery chains 2018-04-03 17:52:54 -07:00
zotlabs
cf6d51bee8 some more work on hubzilla issue #1019 2018-04-02 22:47:11 -07:00
zotlabs
d68ce0f345 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-04-02 20:45:18 -07:00
zotlabs
4e21c14ff6 community tagging refactor - we no longer send an edited post/comment to everybody. The post owner approves the tag and this is transmitted along with the tag activity. Recipients check the signature of the approval and add the tag to their local copy of the post. 2018-04-02 20:39:28 -07:00
zotlabs
753e1e4616 commtag refactor 2018-04-02 19:32:22 -07:00
zotlabs
9a1f051068 missing year on profile birthday input, some optimisations to stats 2018-04-02 13:32:10 -07:00
zotlabs
bcffb6cf55 obscurify chats 2018-04-01 16:53:10 -07:00
Mario Vavti
0e09dca952 fix missing login/out buttons for medium screensize 2018-04-01 20:19:56 +02:00
zotlabs
3bd3686acf Merge branch 'oauth2' of https://github.com/anaqreon/hubzilla into oauth2 2018-03-31 14:00:09 -07:00
zotlabs
4493304fa7 wrong function 2018-03-31 13:22:12 -07:00
Andrew Manning
6decffb00c Merge branch 'dev' into oauth2 2018-03-31 13:41:29 -04:00
zotlabs
54e941724f Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-31 01:45:26 -07:00
zotlabs
e155e7d9ce undo vcard on display module until we can make it accurate 2018-03-31 01:43:33 -07:00
Mario Vavti
6433ce70a1 Merge remote-tracking branch 'mike/master' into dev 2018-03-31 09:26:58 +02:00
zotlabs
1e086a4ac8 Hubzilla issue #1022 cleanup of post formatting 2018-03-30 17:13:21 -07:00
zotlabs
1c3e669761 Hubzilla issue #1022 - improve the usability 2018-03-30 16:47:47 -07:00
zotlabs
af125fbe4f Hubzilla issue #1022 - provide a way to share wiki pages. Currently this is only implemented in the 'edit' pane and could use some improvement/enhancement 2018-03-30 16:09:25 -07:00
zotlabs
43249bd4be hubzilla issue #1020 - PM using unicode domain for recipient. May require further testing 2018-03-30 15:18:33 -07:00
zotlabs
f54aa4f21e allow case independence of replacements as well as patterns 2018-03-30 01:59:32 -07:00
Mario Vavti
6822415ee2 Merge remote-tracking branch 'mike/master' into dev 2018-03-30 09:07:43 +02:00
zotlabs
6d0e1b0e07 display and link issues with quoted tags 2018-03-29 17:06:23 -07:00
zotlabs
238303d819 add directory keyword links to profile 2018-03-29 15:32:35 -07:00
zotlabs
998f39868f directory: link entry keywords to a directory keyword search 2018-03-29 14:27:26 -07:00
mrjive
20ac91703d Merge pull request #1 from redmatrix/dev
Dev
2018-03-29 17:47:50 +02:00
zotlabs
33bb89729c hubzilla issue #1019 - punycode urls on connedit page when displaying locations 2018-03-29 02:26:25 -07:00
Mario Vavti
e06e64823f bump version 2018-03-29 10:30:32 +02:00
zotlabs
cd485b0fdf hubzilla issue #1015 - login with unicode domain name 2018-03-28 19:25:11 -07:00
zotlabs
1cf0de568d use context method 2018-03-28 18:32:04 -07:00
zotlabs
662316e687 update folder timestamp on uploaded files (fixme - we need to recurse back to the storage root but that is for another day) 2018-03-27 21:13:14 -07:00
zotlabs
14383a4c4a uexport: set content-type to json and add sections info to the default filename if present 2018-03-27 18:43:59 -07:00
Andrew Manning
1dc795722a Merge branch 'dev' into oauth2 2018-03-27 21:11:34 -04:00
zotlabs
08274ffab7 put vcard widget with author of top-level post on display page 2018-03-27 18:01:20 -07:00
zotlabs
5ea11d1222 don't include the q and PHPSESSID request variables in a redirected rpost 2018-03-27 16:27:28 -07:00
zotlabs
35b6c2baad Hard fail imports of removed channels. This is silly. 2018-03-27 15:08:27 -07:00
zotlabs
a92f22a4a4 IDN: force baseurl to be punycode; for consistency and federation all internal urls are US-ASCII, unicode MAY be used for display. 2018-03-25 23:02:41 -07:00
zotlabs
2fc3f381ac php strpos() empty needle warning when a term entry has no url 2018-03-25 21:48:42 -07:00
zotlabs
2a2a21a736 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-25 21:17:34 -07:00
zotlabs
5a739ddc47 Merge branch 'newmemberwidget' 2018-03-25 21:16:10 -07:00
zotlabs
4ef2493e95 testing start_menu feature 2018-03-25 21:15:23 -07:00
Mario Vavti
c98776923a Merge remote-tracking branch 'mike/master' into dev 2018-03-25 11:21:24 +02:00
zotlabs
bb4f9eecbe preserve existing categories when updating an app from an embed source 2018-03-24 21:17:15 -07:00
zotlabs
d4e91d5d9b app sellpage not being stored 2018-03-24 15:13:19 -07:00
zotlabs
558e3f8042 code optimisations and de-duplication on updating parent commented timestamp 2018-03-24 02:22:24 -07:00
Mario Vavti
9f9b9dfd82 Merge remote-tracking branch 'mike/master' into dev 2018-03-24 09:12:48 +01:00
zotlabs
a8d81a68d6 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-23 21:44:55 -07:00
zotlabs
abe6ab4775 logic fallacy when updating parent timestamp of moderated comment 2018-03-23 21:24:24 -07:00
zotlabs
9a155cf5a5 turn newmember widget into a feature 2018-03-23 19:03:30 -07:00
Mario Vavti
ae9e64cedf prevent reload loop if somebody lands on /ochannel (without channel_address and without trailing slash) 2018-03-23 10:37:10 +01:00
zotlabs
e6d62f6e05 Add Ochannel module for testing OStatus bad behaviour 2018-03-23 10:36:56 +01:00
goofy-bz
09567da292 Update hmessages.po
typofix
2018-03-23 10:30:40 +01:00
fadelkon
a1ce5df74f Update translations for catalan (ca/ca_ES) from transifex 2018-03-23 10:29:57 +01:00
git-marijus
dede5fabeb Merge pull request #1004 from goofy-bz/patch-1
Update hmessages.po
2018-03-23 10:27:56 +01:00
git-marijus
4a4c18b8b3 Merge pull request #1008 from fadelkon/update_cat_translation
Update translations for catalan (ca/ca_ES) from transifex
2018-03-23 10:27:17 +01:00
git-marijus
06026c1c27 Merge pull request #1009 from dawnbreak/QA_testing
👷Extend Travis, add PostgreSQL10.
2018-03-23 10:26:26 +01:00
git-marijus
e2b9162a30 Merge pull request #1010 from dawnbreak/dev
⬆️ Update libraries.
2018-03-23 10:25:58 +01:00
Mario Vavti
eec4d9b5ad an attemot to fix the PermissionRolesTest 2018-03-23 10:16:06 +01:00
Mario Vavti
376091010f Merge remote-tracking branch 'mike/master' into dev 2018-03-23 10:03:54 +01:00
Mario Vavti
ac967db4e8 new markdown lib seems to handle < and > correct. remove the workaraound. 2018-03-23 09:40:24 +01:00
zotlabs
af8cbf000f tagadelic was being overly protective of permissions. 2018-03-22 21:23:12 -07:00
zotlabs
034032c7c2 slight change in mail privacy implementation. If you initiate a private mail conversation and they respond, accept the reply. You can't hide behind your permissions or lack thereof. Often this will be accidental. If you truly want to block them from replying and your permissions otherwise would not allow them to reply, delete the conversation. 2018-03-22 19:52:25 -07:00
zotlabs
05e11844e5 make list mode work in cards and articles 2018-03-22 17:17:00 -07:00
zotlabs
4ba91cf4e3 make alt_pager work for articles/cards 2018-03-22 16:34:27 -07:00
zotlabs
9a52b90f22 hubzilla issue #1013 - comments not displayed in single card/article view 2018-03-22 15:38:00 -07:00
Mario Vavti
8ea8700eef prevent reload loop if somebody lands on /ochannel (without channel_address and without trailing slash) 2018-03-22 13:55:23 +01:00
zotlabs
1f128e84fb Hubzilla issue #1006, fix anonymous comments bump thread before being approved. 2018-03-21 22:52:24 -07:00
zotlabs
1514b0f4e5 initial support for alternative sort orders on the cloud pages. Can be triggered manually but further development is required. 2018-03-21 21:19:18 -07:00
zotlabs
dc066d4c9b Add Ochannel module for testing OStatus bad behaviour 2018-03-21 15:44:56 -07:00
zotlabs
3d6b606792 add the social "party" permission role 2018-03-20 04:08:36 -07:00
Klaus Weidenbach
c80837a9e6 ⬆️ Update libraries.
michelf/php-markdown (1.7.0 => 1.8.0)
ezyang/htmlpurifier (v4.9.3 => v4.10.0)
commerceguys/intl (v0.7.4 => v0.7.5)
sabre/http (4.2.3 => v4.2.4)
sabre/vobject (4.1.3 => 4.1.5)
2018-03-18 02:15:29 +01:00
Klaus Weidenbach
a732b2bca1 👷Extend Travis, add PostgreSQL10.
Add PostgreSQL10 to TravisCI through Docker container.
Use PHP7.2 instead of PHP7.1 as default test environment.
Update to current stable MariaDB 10.2 from stable (GA) 10.1.
2018-03-17 23:27:56 +01:00
Mario Vavti
0009f7f051 do not include pending registrations in accounts and goaway to /admin/accounts after approval or denial of an pending registration 2018-03-17 21:52:56 +01:00
fadelkon
7b04c7e7df Update translations for catalan (ca/ca_ES) from transifex 2018-03-17 19:03:10 +01:00
Mario Vavti
b5cc26fe76 Merge remote-tracking branch 'mike/master' into dev 2018-03-17 09:02:48 +01:00
goofy-bz
b3cb78a598 Update hmessages.po
typofix
2018-03-17 08:24:16 +01:00
zotlabs
60b38a3a52 slight re-org and update of documentation, moving the tutorial to the top. 2018-03-16 15:34:09 -07:00
Mario Vavti
c0a896ff5e change hearts for heart in reactions but cheet with the unicode 2018-03-16 12:03:52 +01:00
Mario Vavti
63bbde2368 use transform to scale emojis. this prevents text jumping on hover 2018-03-16 11:03:22 +01:00
zotlabs
91b710b07d add auth flag to share attributes so we can make a costly determination to use zid at post submission time instead of making multiple calls to is_matrix_url() at render time 2018-03-15 17:51:24 -07:00
Mario Vavti
34fee2a790 match hosts instead of urls to decide if to zid or not to zid 2018-03-15 14:53:18 +01:00
Mario Vavti
6c709551ce do not always zid share links. add missing < 2018-03-15 14:31:50 +01:00
Mario Vavti
aa4f8b2901 add xchan_network = zot and xchan_deleted = 0 to the random_profile() query 2018-03-15 13:34:40 +01:00
Mario Vavti
3003f85a3e fix channel_address 2018-03-15 11:09:58 +01:00
Mario Vavti
33573edafa make the oneway-overlay slightly opaque 2018-03-15 11:09:22 +01:00
Mario Vavti
95c53c7e0b add zotadel.net to directory fallback servers 2018-03-15 10:13:30 +01:00
zotlabs
a94a28bb7e mastodon content-warning cont: only strip nsfw tag if a content warning spoiler is used. Else it's legitimately nsfw. 2018-03-14 20:47:11 -07:00
zotlabs
7b56fdebac more work with unicode usernames 2018-03-14 18:42:07 -07:00
zotlabs
0905018d3b use original exif_read_data() parameters which were lost in a regression; unset automatic nsfw category generated for Mastodon content warning posts, as people use CW as a spoiler mechanism 99% of the time and flagging inappropriate content 1% of the time. 2018-03-14 14:51:33 -07:00
Mario Vavti
9d230b1f4c indicate that there are events today in notifications by changing the badge class from secondary to danger. issue #1001 2018-03-14 21:39:33 +01:00
Mario Vavti
9f4064e03b update justified gallery lib from 3.6.3 to 3.6.5 2018-03-14 11:49:19 +01:00
Mario Vavti
461e86423a Merge remote-tracking branch 'mike/master' into dev 2018-03-14 11:37:24 +01:00
Mario Vavti
f70413a031 fix channel_address 2018-03-14 10:47:36 +01:00
Mario Vavti
26b7a3aca0 make the oneway-overlay slightly opaque 2018-03-14 10:33:23 +01:00
Mario Vavti
75721b7e82 reveal the profile name field only if multi prifiles feature is enabled 2018-03-14 10:24:08 +01:00
Mario Vavti
fa3e7a574f show site registration notifications setting only to site admin 2018-03-14 10:03:17 +01:00
Mario Vavti
d4fa33dddd whitespace 2018-03-14 09:19:06 +01:00
zotlabs
a0cbed80f3 make unicode usernames work in chanview module 2018-03-14 00:50:12 -07:00
zotlabs
128d1f7aa8 somewhere along the line the output of exif_read_data() changed and it no longer provides populated sections. Adjust for the new format and allow for the old because I cannot find documentation of this change anywhere. This affects photo rotation and the photo map feature. 2018-03-13 22:47:11 -07:00
Mario Vavti
09a841f3be add ability to disable newmember widget ahead of time 2018-03-13 15:20:32 +01:00
mrjive
074bf009d8 Partial italina translationhmessages.po hstrings.php 2018-03-13 12:02:06 +01:00
git-marijus
268b96effa Merge pull request #1000 from mrjive/dev
Connections page filtering for active connections
2018-03-13 12:01:23 +01:00
Manuel Jiménez Friaza
5a3c2b19c9 Spanish translation: adapted the new timeago's stuff 2018-03-13 11:59:36 +01:00
git-marijus
b120394b49 Merge pull request #999 from mjfriaza/dev
Spanish translation: adapted the new timeago's stuff
2018-03-13 11:58:40 +01:00
Manuel Jiménez Friaza
46c67e7f2f Spanish translation: adapted the new timeago's stuff 2018-03-13 11:20:08 +01:00
mrjive
790660e612 Merge pull request #18 from redmatrix/dev
Dev
2018-03-13 10:59:21 +01:00
mrjive
2bcfa0c126 small work on connections page 2018-03-13 02:57:08 -07:00
Mario Vavti
e02029ecc6 bump version 2018-03-13 09:46:11 +01:00
git-marijus
53c1d3775c Merge pull request #997 from mjfriaza/dev
Spanish translation: added "el" before "artículo", which is the correct construction
2018-03-13 09:37:16 +01:00
Mario Vavti
150e238b02 Merge remote-tracking branch 'mike/master' into dev 2018-03-13 09:05:40 +01:00
zotlabs
ab1d47b36f unicode/emoji usernames. Warning: experimental feature, unstable, untested, disabled by default, use at your own risk, may not federate to other platforms and protocols. May not clone correctly. Bug reports which neglect to include detailed roubleshooting information and patches/pull requests will be ignored. 2018-03-12 20:54:55 -07:00
Andrew Manning
dcd658f12e Merge branch 'dev' into oauth2 2018-03-12 19:50:25 -04:00
zotlabs
34399b8b47 obscure permission issue with custom permissions when using the highly discouraged advisory privacy modes 2018-03-12 15:47:33 -07:00
Mario Vavti
b265a55b81 Merge remote-tracking branch 'mike/master' into dev 2018-03-12 09:37:29 +01:00
zotlabs
717ae54868 Setup - .htconfig.php write access is now required for automated installation. [String change - leave in dev for the next release] 2018-03-11 16:42:46 -07:00
Mario Vavti
ade11568f9 update mysql schema 2018-03-11 13:53:53 +01:00
Manuel Jiménez Friaza
ec12b78ddf Spanish translation: added el before artículo, which is the correct construction. 2018-03-11 13:07:11 +01:00
zotlabs
08d2adddf5 remove debugging 2018-03-10 13:21:22 -08:00
zotlabs
a417389934 trim expects error ... in admin/site 2018-03-10 13:20:20 -08:00
Andrew Manning
aa6f7481a0 Fixed access_token request bug and returned oauth2-server-php library to unmodified state. 2018-03-10 15:43:13 -05:00
Mario Vavti
cd21519de3 do not use trim on array 2018-03-10 21:21:44 +01:00
Andrew Manning
a4de63ca92 Merge branch 'dev' into oauth2 2018-03-10 15:10:09 -05:00
Mario Vavti
78040330b6 update changelog 2018-03-09 11:06:05 +01:00
git-marijus
4fdad3b8af Merge pull request #994 from Reylak/dev
RedBasic theme dark schema update
2018-03-09 09:21:52 +01:00
Mario Vavti
9c02c66ed3 remove redundant comma 2018-03-09 09:17:57 +01:00
Mario Vavti
d82bf2b921 Merge remote-tracking branch 'mike/master' into dev 2018-03-09 09:04:14 +01:00
zotlabs
3ee35b83c2 notifications-btn-1 does not actually require the text-white class and this is known to cause issues on dark themes 2018-03-08 14:23:34 -08:00
Mathieu "Matbac" Bacou
500b141341 Uniformize title input with other input fields
Add rounded corners to mimic categories input field and main text area.
2018-03-08 21:12:33 +01:00
Mathieu "Matbac" Bacou
f9cca2422a Remove useless background spec for category field 2018-03-08 21:02:51 +01:00
Mathieu "Matbac" Bacou
76a8006003 Fix background of tags field 2018-03-08 20:56:23 +01:00
Mathieu "Thrar" Bacou
7ac70e1f23 Fix code background in wiki pages
Fix needed after commit c444e40c01
2018-03-08 20:14:44 +01:00
Mario
a0a1246efb use dbunescbin() for cover photos 2018-03-08 10:52:49 +01:00
Mario
2105cfd433 fix syntax error in postgres update 2018-03-08 10:27:43 +01:00
Mario Vavti
f3a753bda6 Merge remote-tracking branch 'mike/master' into dev 2018-03-08 08:55:25 +01:00
zotlabs
1700aedbed remove extraneous logging 2018-03-07 17:29:01 -08:00
zotlabs
48b1042347 hashtag autocomplete 2018-03-07 16:59:55 -08:00
zotlabs
a454aad124 federated polls: GNU-Social requires us to preserve the original order of the poll answers for use in making a vote, unlike diaspora (which selects by guid) and activitypub (which selects by non-localisable text). 2018-03-07 15:39:14 -08:00
Mario Vavti
17c102ebe1 we need the javascript in the template since strings are involved 2018-03-07 21:11:57 +01:00
Mario Vavti
d6812cf75e more bootstrap accordion fixes 2018-03-07 20:47:18 +01:00
Mario Vavti
04f7f99fc3 we do not support separate mobile themes anymore 2018-03-07 20:29:37 +01:00
zotlabs
f0f58dade8 federated polls: add poll_author which will be necessary for Diaspora federation 2018-03-06 15:31:45 -08:00
zotlabs
b282e45a02 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-06 15:23:05 -08:00
zotlabs
0a876e1518 don't add pending connections to the default privacy group until accepted 2018-03-06 11:39:49 -08:00
Mario Vavti
da9fe27db1 update changelog 2018-03-06 11:15:47 +01:00
git-marijus
c7351c0922 Merge pull request #991 from anaqreon/dev
Improve rendering of Readme files in plugin settings
2018-03-06 08:49:06 +01:00
Andrew Manning
99247d0c59 Improve rendering of Readme files in plugin settings 2018-03-05 20:42:06 -05:00
Andrew Manning
9b13db1c48 Merge branch 'dev' into oauth2 2018-03-05 20:06:47 -05:00
Mario Vavti
c462d2f15e add pdl file for mod moderate 2018-03-05 23:03:58 +01:00
Mario Vavti
bae2af09a0 fix javascript error if there are no notifications 2018-03-05 22:59:05 +01:00
Mario Vavti
a0e0b82067 update redbasic theme screenshot 2018-03-05 22:39:27 +01:00
mrjive
9fb65e10bd Partial italina translationhmessages.po hstrings.php 2018-03-05 05:37:15 -08:00
Mario Vavti
a0e390c6c8 Merge remote-tracking branch 'mike/master' into dev 2018-03-05 08:54:46 +01:00
git-marijus
fd7d3f9286 Merge pull request #989 from phellmes/dev
Update DE translation strings (for 3.2RC)
2018-03-05 08:53:03 +01:00
zotlabs
59a2057fa0 fix some issues with friend suggestions on standalone sites with no 'suggestme' volunteers. This wrongly pulled up a site directory suggesting everybody on the site. While a better outcome than finding nobody, this does not fit with our ethical design goals. If there are no friends of friends, we will only suggest those who volunteer to be on the default suggestion list. Also do not attempt to load poco data from dead sites. 2018-03-04 17:40:38 -08:00
zotlabs
be6619d9c0 bugfix: unable to reset profile fields to defaults in admin/profs by emptying the textarea 2018-03-04 15:29:10 -08:00
phellmes
bb7457f43c Update DE translation strings 2018-03-05 00:24:41 +01:00
zotlabs
14f701f7fc restrict mail messages to max_import_size 2018-03-04 14:30:09 -08:00
Andrew Manning
058f7277b5 Merge branch 'dev' into oauth2 2018-03-04 06:45:07 -05:00
zotlabs
471c3c4d06 add dummy f= arg to suggestion urls, use directory version of suggest for newmember link instead of the suggest module as the UI is prettier. 2018-03-03 15:54:13 -08:00
zotlabs
ca1022675c There was no pdl for mod_thing; add one because it's only a link away from profile creation and remains on that page until you go elsewhere and new members may need help to find their way out 2018-03-03 15:19:39 -08:00
zotlabs
c3920116f2 more work on federated polls 2018-03-03 13:52:55 -08:00
zotlabs
26e0fd624a Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-02 20:08:01 -08:00
zotlabs
4c69c56797 string change "Channel added" -> "Connection added" 2018-03-02 14:09:59 -08:00
zotlabs
df03805579 process follow from article menu in the background, do not reload page - hubzilla issue #987 2018-03-02 13:15:28 -08:00
zotlabs
b38ce967f3 sort settings/featured 2018-03-02 12:41:50 -08:00
zotlabs
dbe73cdcbe add icon to any addon settings blocks which don't already have one 2018-03-02 12:04:23 -08:00
git-marijus
2f0ebdeade Merge pull request #985 from mjfriaza/dev
Updated Spanish translation (hmessages.po/php and register_verify_member.tpl).
2018-03-02 20:46:34 +01:00
Mario Vavti
7c5f1e814b Merge remote-tracking branch 'mike/master' into dev 2018-03-02 20:25:17 +01:00
Manuel Jiménez Friaza
840cea680c New strings for Spanish translation. 2018-03-02 18:28:42 +01:00
Mario Vavti
5c46e66694 update DB update 1205 to mitigate
ERROR 1069 (42000): Too many keys specified; max 64 keys allowed
2018-03-02 11:38:21 +01:00
Mario Vavti
bca05dc89f bump version 2018-03-02 10:23:53 +01:00
Mario Vavti
6ee6285670 db update to drop index resource_type. we have uid_resource_type now. 2018-03-02 10:10:29 +01:00
zotlabs
dcfe9bc64f background work for caldav integration continued, modify mod_follow to allow it to be called from ajax without redirecting. 2018-03-02 01:03:14 -08:00
zotlabs
8fd619da71 zot revision => 6.0a, not yet needed or referenced 2018-03-01 16:42:32 -08:00
zotlabs
1620691cbe add federation property to webfinger 2018-03-01 16:38:14 -08:00
zotlabs
49bd859136 Merge branch 'dev' of https://github.com/redmatrix/hubzilla into xdev_merge 2018-03-01 16:16:58 -08:00
zotlabs
93a11ade04 sigh - missed two strings 2018-03-01 16:11:30 -08:00
Manuel Jiménez Friaza
3da9107354 Updated Spanish translation (hmessages.po/php and register_verify_member.tpl). 2018-03-01 19:41:59 +01:00
Mario Vavti
d32f583fda Merge branch 'dev' of https://github.com/redmatrix/hubzilla into dev 2018-03-01 13:46:39 +01:00
Mario Vavti
bab00731a8 fix issues with accordions in settings and comment out jquery.textinputs.js 2018-03-01 13:46:25 +01:00
git-marijus
8cd539e125 Merge pull request #984 from dawnbreak/dev
Update composer autoload cache.
2018-03-01 12:08:31 +01:00
git-marijus
3b8a0d4773 Merge pull request #983 from dawnbreak/QA_testing
 Unit Test for HTTPSig.
2018-03-01 12:07:37 +01:00
Klaus Weidenbach
b60098ec68 Update composer autoload cache. 2018-03-01 11:29:15 +01:00
Mario Vavti
de02fddf89 update strings 2018-03-01 08:54:09 +01:00
Mario Vavti
2e058c9abc version 2018-03-01 08:42:02 +01:00
Andrew Manning
39fe80a196 Merge branch 'dev' into oauth2 2018-02-28 20:47:14 -05:00
Klaus Weidenbach
7c28a40c3e Unit Test for HTTPSig. 2018-02-28 16:04:13 +01:00
Andrew Manning
1035c453ea Merge branch 'dev' into oauth2 2018-02-26 19:48:15 -05:00
Andrew Manning
45e0fc6802 Successful OAuth2 sequence demonstrated with the test vehicle, including an authenticated API call using an access_token. 2018-02-26 18:16:43 -05:00
Andrew Manning
e3095ce6b2 Merge branch 'dev' into oauth2 2018-02-25 08:36:52 -05:00
Andrew Manning
70b8f3240f An authorization token is received, but I had to modify the Request class in vendor/bshaffer/oauth2-server-php/ to accept $_REQUEST instead of $_POST. 2018-02-25 08:36:40 -05:00
Andrew Manning
497ebca54f Merge branch 'dev' into oauth2 2018-02-24 06:48:56 -05:00
Andrew Manning
64ee42fc3d Add channel ID to user_id in clients table. Added TODO comments about dynamic client registration protocol. 2018-02-24 06:48:30 -05:00
Andrew Manning
70719c67d3 Merge branch 'dev' into oauth2 2018-02-22 15:10:20 -05:00
Andrew Manning
43fca182e3 The authorization step with client registration and authorization code retrieval working. Might not conform perfectly to OAuth2 spec, but it is a start. 2018-02-22 15:10:05 -05:00
mrjive
2d17e1c677 Merge pull request #15 from redmatrix/dev
Dev
2018-02-21 12:55:29 +01:00
Andrew Manning
8e5c1135c3 Merge branch 'dev' into oauth2 2018-02-20 21:11:59 -05:00
Andrew Manning
89a825cd03 OAuth2TestVehicle module can create and delete oauth2 database tables. 2018-02-20 21:11:38 -05:00
Andrew Manning
7d0c1bb737 Created test vehicle module oauth2test 2018-02-18 20:24:41 -05:00
mrjive
d7ecaa8b23 Merge pull request #14 from redmatrix/dev
Dev
2018-02-02 09:23:55 +01:00
mrjive
7ac4b47702 Merge pull request #13 from redmatrix/dev
Dev
2018-01-30 16:13:30 +01:00
mrjive
c2abbe2c23 small changes
changed icon from sort to filter and changed id to class in content-wrapper clearfix
2018-01-29 16:33:54 +01:00
mrjive
5f6f87a7cd Update connections.tpl 2018-01-29 16:32:32 +01:00
mrjive
4b7967b938 Merge pull request #12 from redmatrix/dev
Dev
2018-01-26 09:43:47 +01:00
mrjive
f560a3c98f Merge pull request #11 from redmatrix/dev
Dev
2018-01-24 18:30:59 +01:00
mrjive
131baa9f45 Merge pull request #10 from redmatrix/dev
Dev
2018-01-22 09:34:08 +01:00
mrjive
8e475810a7 Merge pull request #8 from redmatrix/dev
section-content-info-wrapper for register text
2018-01-18 10:40:15 +01:00
mrjive
e81949bb09 Merge pull request #7 from redmatrix/dev
Dev
2018-01-16 11:45:01 +01:00
1113 changed files with 98963 additions and 67519 deletions

View File

@@ -62,28 +62,34 @@ matrix:
fast_finish: true
# Additional check combinations
include:
# PHP7.1, mariadb 10.1
- php: '7.1'
env: DB=mariadb MARIADB_VERSION=10.1 CODECOV=1
# PHP7.2, mariadb 10.2
- php: '7.2'
env: DB=mariadb MARIADB_VERSION=10.2 CODECOV=1
# use mariadb instead of MySQL
addons:
mariadb: '10.1'
# PHP7.1, PostgreSQL 9.6
- php: '7.1'
mariadb: '10.2'
# PHP7.2, PostgreSQL 9.6
- php: '7.2'
env: DB=pgsql POSTGRESQL_VERSION=9.6 PHPUNITFILE=phpunit-pgsql.xml
# Use newer postgres than 9.2 default
addons:
postgresql: '9.6'
services:
- postgresql
# PHP7.1, old precise distribution with MySQL 5.5
- php: '7.1'
# PostgreSQL 10 with Docker container
- php: '7.2'
env: DB=pgsql POSTGRESQL_VERSION=10 PHPUNITFILE=phpunit-pgsql.xml
sudo: required
services:
- docker
# PHP7.2, old precise distribution with MySQL 5.5
- php: '7.2'
env: DB=mysql MYSQL_VERSION=5.5
dist: precise
services:
- mysql
# MySQL 5.7 with Docker container
- php: '7.1'
- php: '7.2'
env: DB=mysql MYSQL_VERSION=5.7
sudo: required
services:
@@ -109,6 +115,8 @@ before_install:
- travis_retry composer self-update
# Start MySQL 5.7 Docker container, needs some time to come up
- if [[ "$MYSQL_VERSION" == "5.7" ]]; then sudo service mysql stop; docker run -d -p 3306:3306 -e MYSQL_ALLOW_EMPTY_PASSWORD=yes mysql:5.7 && sleep 25 && docker ps; fi
# Start PostgreSQL 10 Docker container, needs some time to come up
- if [[ "$POSTGRESQL_VERSION" == "10" ]]; then sudo service postgresql stop; docker run -d -p 5432:5432 postgres:10-alpine && sleep 35 && docker ps; fi
# Install composer dev libs
install:

100
CHANGELOG
View File

@@ -1,3 +1,103 @@
Hubzilla 3.4.1 (2018-06-08)
- Say bye, bye to GitHub and move sourcecode repositories to #^https://framagit.org/hubzilla
- When removing a connection, don't remove items that are starred, filed or replied to
- Do not show archived forums in forum widget
- Fix potential XSS vulnerabilities
- Translation updates
- Fix postresql issue with oauth2
- Improve abconfig queries
- Fix postgresql issue if register mode was set to yes - with approval
Addons
- Diaspora: fix likes of non-contacts not allowed to like allthough diaspora_public_comments is set
- Pubcrawl: fix wrong hubloc url
- Pubcrawl: fix issues with attachments
- Pubcrawl: fetch required item metadata in asfetch_item()
- Cavatar: use cavatar for all default profile photos if enabled
- Pubcrawl: fix peertube video display
- Pubcrawl: fix incoming activitypub comments not getting propagated downstream
- Statistics: fix .well-known/nodeinfo
- Pubsubhubbub: fix postgresql related issues
- Pubcrawl: send the original LD-signature signed activity when distributing comments downstream if we have it
- Cavatar: improve the image creation process
Hubzilla 3.4 (2018-05-04)
- Provide warnings about profile photo and cover photo permissions
- Don't duplicate addressbook entries on repeated channel imports
- Where possible strip zid parameter from links that get pasted into posts so that they will get a correct zid when rendered
- Rename boxy schema to Focus-Boxy
- Rename BS-Default schema to Focus-Light
- Mark simple_* schemas unmaintained and deprecated - they will be removed in next release if nobody steps up to maintain them.
- Implement trending tags for mod pubstream
- Relax restrictions to the design tools menu to allow those with write_pages permission
- Add alt pager to mod moderate
- Show existing cover photo when changing it
- Update to bootstrap lib to version 4.1
- Provide a higher accuracy method for active channels information
- Provide visible star status for starred posts
- Move the thread author menu to the wall item photo
- Accept system_language through either get or post
- Remove recipient name from stored notifications but keep them in emails
- Fix issue of being forced to log back in after leaving a delegated channel
- Implement last commented expiration setting in mod admin
- Create catcloud widget and provide a type option which can include 'cards' or 'articles'
- Modified notifications widget to add the public stream when the current user is allowed to see it only
- Don't provide a connect button for transient identities
- Merge techlevels and features
- Implement auto-save posts and comments in browser using localStorage
- Display directory server in siteinfo.json
- Bring back the dnt policy document
- Implement OAuth2/OpenIDConnect server
- Add basic structure for additional features documentation
- Community tag refactor
- Obscurify chats
- Provide a way to share wiki pages
- Update folder timestamp on uploaded files
- Code optimisations and de-duplication on updating parent commented timestamp
- Turn newmember widget into a feature
- Make list mode work in cards and articles
- Make alt pager work for articles and cards
- Initial support for alternative sort orders on the cloud pages
- Add Ochannel module for testing OStatus bad behaviour
- Add the social - federation permission role
- Update justified gallery lib from 3.6.3 to 3.6.5
Bugfixes
- Fix regression with forum widget unseen count
- Fix issue with imagemagick exif info
- Aonymous comments in StdLimits shouldn't be allowed
- Fix wiki pages not syncing
- Show "Unseen public activity" channel setting when site only public streams are activated
- Fix channel import failing to provide channel_password value
- Fix permalinks to children of articles and cards
- Fix missing year on profile birthday input
- Fix missing login/out buttons for medium screensize
- Preserve existing categories when updating an app from an embed source
- Fix app sellpage not being stored
- Fix tagadelic being overly protective of permissions
- Fix comments not displayed in single card/article view
- Fix anonymous comments bump thread
- Fix pending registrations visible in admin accounts
Addons
Pubcrawl: fix issues with "private" messages
Pubcrawl: fix issues with postgresql
Fuzzloc: new addon to blur your browser location
Pubcrawl: implement follow by webfinger
Cart: new addon which provides online shop functionalities (experimental)
Pubcrawl: implement two-way summary functionality
Wordpress: upgrade incutio xmlrpc library to use hubzilla curl wrapper
Hzfiles: various fixes
Diaspora: support full_name attribute in profile messages
Frphotos: deprecate plugin (keep it for reference)
Webmention: require html5 parser
GNU-Social: provide alternative xchan_url
Diaspora: fix wrong callback function
Diaspora: fix conversion of forum mentions to markdown by providing a !{forum@host} link syntax
Diaspora: fix item title not transferred
Hubzilla 3.2 (2018-03-09)
- Improve rendering of Readme files in plugin settings
- Add pdl file for mod moderate

View File

@@ -5,7 +5,7 @@ Hubzilla - Community Server
<p align="center" markdown="1">
<em><a href="https://github.com/redmatrix/hubzilla/blob/master/install/INSTALL.txt">Installing Hubzilla</a></em>
<em><a href="install/INSTALL.txt">Installing Hubzilla</a></em>
</p>
**What is Hubzilla?**

View File

@@ -41,10 +41,8 @@ class PermissionLimits {
$limits = [];
$perms = Permissions::Perms();
$anon_comments = get_config('system','anonymous_comments',true);
foreach($perms as $k => $v) {
if(strstr($k, 'view') || ($k === 'post_comments' && $anon_comments))
if(strstr($k, 'view'))
$limits[$k] = PERMS_PUBLIC;
else
$limits[$k] = PERMS_SPECIFIC;
@@ -74,13 +72,13 @@ class PermissionLimits {
* @param int $channel_id
* @param string $perm (optional)
* @return
* * \b boolean false if no perm_limits set for this channel
* * \b int if $perm is set, return one of PERMS_* constants for this permission
* * \b false if no perm_limits set for this channel
* * \b int if $perm is set, return one of PERMS_* constants for this permission, default 0
* * \b array with all permission limits, if $perm is not set
*/
static public function Get($channel_id, $perm = '') {
if($perm) {
return PConfig::Get($channel_id, 'perm_limits', $perm);
return intval(PConfig::Get($channel_id, 'perm_limits', $perm));
}
PConfig::Load($channel_id);
@@ -90,4 +88,4 @@ class PermissionLimits {
return false;
}
}
}

View File

@@ -41,6 +41,24 @@ class PermissionRoles {
break;
case 'social_federation':
$ret['perms_auto'] = false;
$ret['default_collection'] = false;
$ret['directory_publish'] = true;
$ret['online'] = true;
$ret['perms_connect'] = [
'view_stream', 'view_profile', 'view_contacts', 'view_storage',
'view_pages', 'view_wiki', 'send_stream', 'post_wall', 'post_comments',
'post_mail', 'chat', 'post_like', 'republish'
];
$ret['limits'] = PermissionLimits::Std_Limits();
$ret['limits']['post_comments'] = PERMS_AUTHED;
$ret['limits']['post_mail'] = PERMS_AUTHED;
$ret['limits']['post_like'] = PERMS_AUTHED;
$ret['limits']['chat'] = PERMS_AUTHED;
break;
case 'social_restricted':
$ret['perms_auto'] = false;
$ret['default_collection'] = true;
@@ -263,6 +281,7 @@ class PermissionRoles {
static public function roles() {
$roles = [
t('Social Networking') => [
'social_federation' => t('Social - Federation'),
'social' => t('Social - Mostly Public'),
'social_restricted' => t('Social - Restricted'),
'social_private' => t('Social - Private')

View File

@@ -75,6 +75,8 @@ class Deliver {
q("delete from dreport where dreport_queue = '%s'",
dbesc($argv[$x])
);
continue;
}
}

View File

@@ -34,7 +34,8 @@ class Expire {
logger('expire: start', LOGGER_DEBUG);
$site_expire = get_config('system', 'default_expire_days');
$site_expire = intval(get_config('system', 'default_expire_days'));
$commented_days = intval(get_config('system','active_expire_days'));
logger('site_expire: ' . $site_expire);
@@ -64,7 +65,7 @@ class Expire {
// if the site or service class expiration is non-zero and less than person expiration, use that
logger('Expire: ' . $rr['channel_address'] . ' interval: ' . $expire_days, LOGGER_DEBUG);
item_expire($rr['channel_id'], $expire_days);
item_expire($rr['channel_id'], $expire_days, $commented_days);
}
}
@@ -85,7 +86,7 @@ class Expire {
logger('Expire: sys interval: ' . $expire_days, LOGGER_DEBUG);
if ($expire_days)
item_expire($x['channel_id'], $expire_days);
item_expire($x['channel_id'], $expire_days, $commented_days);
logger('Expire: sys: done', LOGGER_DEBUG);
}

View File

@@ -785,6 +785,7 @@ class Apps {
dbesc($darray['app_plugin']),
intval($darray['app_deleted'])
);
if($r) {
$ret['success'] = true;
$ret['app_id'] = $darray['app_id'];
@@ -871,6 +872,12 @@ class Apps {
dbesc($darray['app_id']),
intval($darray['app_channel'])
);
// if updating an embed app, don't mess with any existing categories.
if(array_key_exists('embed',$arr) && intval($arr['embed']))
return $ret;
if($x) {
q("delete from term where otype = %d and oid = %d",
intval(TERM_OBJ_APP),

View File

@@ -266,7 +266,7 @@ class Chatroom {
intval($room_id),
dbesc($xchan),
dbesc(datetime_convert()),
dbesc($arr['chat_text'])
dbesc(str_rot47(base64url_encode($arr['chat_text'])))
);
$ret['success'] = true;

View File

@@ -115,6 +115,9 @@ class Enotify {
$always_show_in_notices = get_pconfig($recip['channel_id'],'system','always_show_in_notices');
$vnotify = get_pconfig($recip['channel_id'],'system','vnotify');
$salutation = $recip['channel_name'];
// e.g. "your post", "David's photo", etc.
$possess_desc = t('%s <!item_type!>');
@@ -123,7 +126,7 @@ class Enotify {
logger('notification: mail');
$subject = sprintf( t('[$Projectname:Notify] New mail received at %s'),$sitename);
$preamble = sprintf( t('%1$s, %2$s sent you a new private message at %3$s.'),$recip['channel_name'], $sender['xchan_name'],$sitename);
$preamble = sprintf( t('%1$s sent you a new private message at %2$s.'), $sender['xchan_name'],$sitename);
$epreamble = sprintf( t('%1$s sent you %2$s.'),'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]', '[zrl=$itemlink]' . t('a private message') . '[/zrl]');
$sitelink = t('Please visit %s to view and/or reply to your private messages.');
$tsitelink = sprintf( $sitelink, $siteurl . '/mail/' . $params['item']['id'] );
@@ -142,7 +145,7 @@ class Enotify {
if(array_key_exists('item',$params) && in_array($params['item']['verb'], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) {
if(! $always_show_in_notices) {
if(! $always_show_in_notices || !($vnotify & VNOTIFY_LIKE)) {
logger('notification: not a visible activity. Ignoring.');
pop_lang();
return;
@@ -195,8 +198,7 @@ class Enotify {
//$possess_desc = str_replace('<!item_type!>',$possess_desc);
// "a post"
$dest_str = sprintf(t('%1$s, %2$s %3$s [zrl=%4$s]a %5$s[/zrl]'),
$recip['channel_name'],
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]a %4$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
@@ -204,8 +206,7 @@ class Enotify {
// "George Bull's post"
if($p)
$dest_str = sprintf(t('%1$s, %2$s %3$s [zrl=%4$s]%5$s\'s %6$s[/zrl]'),
$recip['channel_name'],
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]%4$s\'s %5$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
@@ -214,8 +215,7 @@ class Enotify {
// "your post"
if($p[0]['owner']['xchan_name'] == $p[0]['author']['xchan_name'] && intval($p[0]['item_wall']))
$dest_str = sprintf(t('%1$s, %2$s %3$s [zrl=%4$s]your %5$s[/zrl]'),
$recip['channel_name'],
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]your %4$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
@@ -230,7 +230,7 @@ class Enotify {
$subject = sprintf( t('[$Projectname:Notify] Moderated Comment to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
else
$subject = sprintf( t('[$Projectname:Notify] Comment to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s commented on an item/conversation you have been following.'), $recip['channel_name'], $sender['xchan_name']);
$preamble = sprintf( t('%1$s commented on an item/conversation you have been following.'), $sender['xchan_name']);
$epreamble = $dest_str;
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
@@ -249,7 +249,7 @@ class Enotify {
$itemlink = $params['link'];
if (array_key_exists('item',$params) && (! activity_match($params['item']['verb'],ACTIVITY_LIKE))) {
if(! $always_show_in_notices) {
if(! $always_show_in_notices || !($vnotify & VNOTIFY_LIKE)) {
logger('notification: not a visible activity. Ignoring.');
pop_lang();
return;
@@ -296,8 +296,7 @@ class Enotify {
// "your post"
if($p[0]['owner']['xchan_name'] == $p[0]['author']['xchan_name'] && intval($p[0]['item_wall']))
$dest_str = sprintf(t('%1$s, %2$s liked [zrl=%3$s]your %4$s[/zrl]'),
$recip['channel_name'],
$dest_str = sprintf(t('%1$s liked [zrl=%2$s]your %3$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$itemlink,
$item_post_type);
@@ -312,7 +311,7 @@ class Enotify {
// differents subjects for messages on the same thread.
$subject = sprintf( t('[$Projectname:Notify] Like received to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s liked an item/conversation you created.'), $recip['channel_name'], $sender['xchan_name']);
$preamble = sprintf( t('%1$s liked an item/conversation you created.'), $sender['xchan_name']);
$epreamble = $dest_str;
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
@@ -325,10 +324,9 @@ class Enotify {
if($params['type'] == NOTIFY_WALL) {
$subject = sprintf( t('[$Projectname:Notify] %s posted to your profile wall') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s posted to your profile wall at %3$s') , $recip['channel_name'], $sender['xchan_name'], $sitename);
$preamble = sprintf( t('%1$s posted to your profile wall at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, %2$s posted to [zrl=%3$s]your wall[/zrl]') ,
$recip['channel_name'],
$epreamble = sprintf( t('%1$s posted to [zrl=%2$s]your wall[/zrl]') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
@@ -352,9 +350,8 @@ class Enotify {
}
$subject = sprintf( t('[$Projectname:Notify] %s tagged you') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s tagged you at %3$s') , $recip['channel_name'], $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, %2$s [zrl=%3$s]tagged you[/zrl].') ,
$recip['channel_name'],
$preamble = sprintf( t('%1$s tagged you at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s [zrl=%2$s]tagged you[/zrl].') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
@@ -366,9 +363,8 @@ class Enotify {
if ($params['type'] == NOTIFY_POKE) {
$subject = sprintf( t('[$Projectname:Notify] %1$s poked you') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s poked you at %3$s') , $recip['channel_name'], $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, %2$s [zrl=%2$s]poked you[/zrl].') ,
$recip['channel_name'],
$preamble = sprintf( t('%1$s poked you at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s [zrl=%2$s]poked you[/zrl].') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
@@ -384,9 +380,8 @@ class Enotify {
if ($params['type'] == NOTIFY_TAGSHARE) {
$subject = sprintf( t('[$Projectname:Notify] %s tagged your post') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s, %2$s tagged your post at %3$s') , $recip['channel_name'],$sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, %2$s tagged [zrl=%3$s]your post[/zrl]') ,
$recip['channel_name'],
$preamble = sprintf( t('%1$s tagged your post at %2$s'),$sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s tagged [zrl=%2$s]your post[/zrl]') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$itemlink);
@@ -398,9 +393,8 @@ class Enotify {
if ($params['type'] == NOTIFY_INTRO) {
$subject = sprintf( t('[$Projectname:Notify] Introduction received'));
$preamble = sprintf( t('%1$s, you\'ve received an new connection request from \'%2$s\' at %3$s'), $recip['channel_name'], $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, you\'ve received [zrl=%2$s]a new connection request[/zrl] from %3$s.'),
$recip['channel_name'],
$preamble = sprintf( t('You\'ve received an new connection request from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('You\'ve received [zrl=%1$s]a new connection request[/zrl] from %2$s.'),
$siteurl . '/connections/ifpending',
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
$body = sprintf( t('You may visit their profile at %s'),$sender['xchan_url']);
@@ -413,9 +407,8 @@ class Enotify {
if ($params['type'] == NOTIFY_SUGGEST) {
$subject = sprintf( t('[$Projectname:Notify] Friend suggestion received'));
$preamble = sprintf( t('%1$s, you\'ve received a friend suggestion from \'%2$s\' at %3$s'), $recip['channel_name'], $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s, you\'ve received [zrl=%2$s]a friend suggestion[/zrl] for %3$s from %4$s.'),
$recip['channel_name'],
$preamble = sprintf( t('You\'ve received a friend suggestion from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('You\'ve received [zrl=%1$s]a friend suggestion[/zrl] for %2$s from %3$s.'),
$itemlink,
'[zrl=' . $params['item']['url'] . ']' . $params['item']['name'] . '[/zrl]',
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
@@ -664,7 +657,7 @@ class Enotify {
'$banner' => $datarray['banner'],
'$notify_icon' => \Zotlabs\Lib\System::get_notify_icon(),
'$product' => $datarray['product'],
'$preamble' => $datarray['preamble'],
'$preamble' => $salutation . '<br><br>' . $datarray['preamble'],
'$sitename' => $datarray['sitename'],
'$siteurl' => $datarray['siteurl'],
'$source_name' => $datarray['source_name'],
@@ -686,7 +679,7 @@ class Enotify {
$email_text_body = replace_macros($tpl, array(
'$banner' => $datarray['banner'],
'$product' => $datarray['product'],
'$preamble' => $datarray['preamble'],
'$preamble' => $salutation . "\n\n" . $datarray['preamble'],
'$sitename' => $datarray['sitename'],
'$siteurl' => $datarray['siteurl'],
'$source_name' => $datarray['source_name'],
@@ -754,8 +747,8 @@ class Enotify {
// generate a mime boundary
$mimeBoundary = rand(0, 9) . "-"
.rand(10000000000, 9999999999) . "-"
.rand(10000000000, 9999999999) . "=:"
.rand(100000000, 999999999) . "-"
.rand(100000000, 999999999) . "=:"
.rand(10000, 99999);
// generate a multipart/alternative message header

View File

@@ -171,16 +171,23 @@ class NativeWiki {
dbesc(NWIKI_ITEM_RESOURCE_TYPE),
dbesc($resource_id)
);
if($r) {
$q = q("select * from item where resource_type = 'nwikipage' and resource_id = '%s'",
dbesc($r[0]['resource_type'])
dbesc($r[0]['resource_id'])
);
if($q) {
$r = array_merge($r,$q);
}
xchan_query($r);
$sync_item = fetch_post_tags($r);
build_sync_packet($uid,array('wiki' => array(encode_item($sync_item[0],true))));
if($sync_item) {
$pkt = [];
foreach($sync_item as $w) {
$pkt[] = encode_item($w,true);
}
build_sync_packet($uid,array('wiki' => $pkt));
}
}
}

View File

@@ -107,7 +107,7 @@ class Share {
}
public function bbcode() {
$bb = NULL_STR;
$bb = EMPTY_STR;
if(! $this->item)
return $bb;
@@ -123,11 +123,13 @@ class Share {
$bb = substr($this->item['body'], $pos);
} else {
$bb = "[share author='".urlencode($this->item['author']['xchan_name']).
"' profile='".$this->item['author']['xchan_url'] .
"' avatar='".$this->item['author']['xchan_photo_s'].
"' link='".$this->item['plink'].
"' posted='".$this->item['created'].
"' message_id='".$this->item['mid']."']";
"' profile='" . $this->item['author']['xchan_url'] .
"' avatar='" . $this->item['author']['xchan_photo_s'] .
"' link='" . $this->item['plink'] .
"' auth='" . (($this->item['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='" . $this->item['created'] .
"' message_id='" . $this->item['mid'] .
"']";
if($this->item['title'])
$bb .= '[b]'.$this->item['title'].'[/b]'."\r\n";
$bb .= (($is_photo) ? $photo_bb . "\r\n" . $this->item['body'] : $this->item['body']);
@@ -138,4 +140,4 @@ class Share {
}
}
}

View File

@@ -54,7 +54,7 @@ class System {
static public function get_project_srclink() {
if(is_array(\App::$config) && is_array(\App::$config['system']) && \App::$config['system']['project_srclink'])
return \App::$config['system']['project_srclink'];
return 'https://github.com/redmatrix/hubzilla';
return 'https://framagit.org/hubzilla/core.git';
}
static public function get_server_role() {

View File

@@ -238,9 +238,9 @@ class ThreadItem {
'do' => t("Add Star"),
'undo' => t("Remove Star"),
'toggle' => t("Toggle Star Status"),
'classdo' => (intval($item['item_starred']) ? "hidden" : ""),
'classundo' => (intval($item['item_starred']) ? "" : "hidden"),
'isstarred' => (intval($item['item_starred']) ? "starred fa-star" : "unstarred fa-star-o"),
'classdo' => ((intval($item['item_starred'])) ? "hidden" : ""),
'classundo' => ((intval($item['item_starred'])) ? "" : "hidden"),
'isstarred' => ((intval($item['item_starred'])) ? true : false),
'starred' => t('starred'),
);
@@ -733,6 +733,8 @@ class ThreadItem {
$arr = array('comment_buttons' => '','id' => $this->get_id());
call_hooks('comment_buttons',$arr);
$comment_buttons = $arr['comment_buttons'];
$feature_auto_save_draft = ((feature_enabled($conv->get_profile_owner(), 'auto_save_draft')) ? "true" : "false");
$comment_box = replace_macros($template,array(
'$return_path' => '',
@@ -768,7 +770,8 @@ class ThreadItem {
'$anoncomments' => ((($conv->get_mode() === 'channel' || $conv->get_mode() === 'display') && perm_is_allowed($conv->get_profile_owner(),'','post_comments')) ? true : false),
'$anonname' => [ 'anonname', t('Your full name (required)') ],
'$anonmail' => [ 'anonmail', t('Your email address (required)') ],
'$anonurl' => [ 'anonurl', t('Your website URL (optional)') ]
'$anonurl' => [ 'anonurl', t('Your website URL (optional)') ],
'$auto_save_draft' => $feature_auto_save_draft,
));
return $comment_box;

View File

@@ -24,7 +24,7 @@ class Acl extends \Zotlabs\Web\Controller {
function init() {
logger('mod_acl: ' . print_r($_REQUEST,true));
logger('mod_acl: ' . print_r($_REQUEST,true),LOGGER_DATA);
$start = (x($_REQUEST,'start') ? $_REQUEST['start'] : 0);
$count = (x($_REQUEST,'count') ? $_REQUEST['count'] : 500);
@@ -82,7 +82,7 @@ class Acl extends \Zotlabs\Web\Controller {
if($search) {
$sql_extra = " AND groups.gname LIKE " . protect_sprintf( "'%" . dbesc($search) . "%'" ) . " ";
$sql_extra2 = "AND ( xchan_name LIKE " . protect_sprintf( "'%" . dbesc($search) . "%'" ) . " OR xchan_addr LIKE " . protect_sprintf( "'%" . dbesc($search) . ((strpos($search,'@') === false) ? "%@%'" : "%'")) . ") ";
$sql_extra2 = "AND ( xchan_name LIKE " . protect_sprintf( "'%" . dbesc($search) . "%'" ) . " OR xchan_addr LIKE " . protect_sprintf( "'%" . dbesc(punify($search)) . ((strpos($search,'@') === false) ? "%@%'" : "%'")) . ") ";
// This horrible mess is needed because position also returns 0 if nothing is found.
// Would be MUCH easier if it instead returned a very large value
@@ -92,10 +92,10 @@ class Acl extends \Zotlabs\Web\Controller {
$order_extra2 = "CASE WHEN xchan_name LIKE "
. protect_sprintf( "'%" . dbesc($search) . "%'" )
. " then POSITION('" . protect_sprintf(dbesc($search))
. "' IN xchan_name) else position('" . protect_sprintf(dbesc($search)) . "' IN xchan_addr) end, ";
. "' IN xchan_name) else position('" . protect_sprintf(dbesc(punify($search))) . "' IN xchan_addr) end, ";
$col = ((strpos($search,'@') !== false) ? 'xchan_addr' : 'xchan_name' );
$sql_extra3 = "AND $col like " . protect_sprintf( "'%" . dbesc($search) . "%'" ) . " ";
$sql_extra3 = "AND $col like " . protect_sprintf( "'%" . dbesc(($col === 'xchan_addr') ? punify($search) : $search) . "%'" ) . " ";
}
else {
@@ -435,7 +435,7 @@ class Acl extends \Zotlabs\Web\Controller {
$count = (x($_REQUEST,'count') ? $_REQUEST['count'] : 100);
if($url) {
$query = $url . '?f=' . (($token) ? '&t=' . urlencode($token) : '');
$query .= '&name=' . urlencode($search) . "&limit=$count" . (($address) ? '&address=' . urlencode($search) : '');
$query .= '&name=' . urlencode($search) . "&limit=$count" . (($address) ? '&address=' . urlencode(punify($search)) : '');
$x = z_fetch_url($query);
if($x['success']) {

View File

@@ -133,12 +133,13 @@ class Accounts {
$base = z_root() . '/admin/accounts?f=';
$odir = (($dir === 'asc') ? '0' : '1');
$users = q("SELECT account_id , account_email, account_lastlog, account_created, account_expires, account_service_class, ( account_flags & %d ) > 0 as blocked,
(SELECT %s FROM channel as ch WHERE ch.channel_account_id = ac.account_id and ch.channel_removed = 0 ) as channels FROM account as ac
where true $serviceclass order by $key $dir limit %d offset %d ",
where true $serviceclass and account_flags != %d order by $key $dir limit %d offset %d ",
intval(ACCOUNT_BLOCKED),
db_concat('ch.channel_address', ' '),
intval(ACCOUNT_BLOCKED | ACCOUNT_PENDING),
intval(\App::$pager['itemspage']),
intval(\App::$pager['start'])
);
@@ -203,4 +204,4 @@ class Accounts {
}
}
}

View File

@@ -39,9 +39,10 @@ class Site {
$site_location = ((x($_POST,'site_location')) ? notags(trim($_POST['site_location'])) : '');
$frontpage = ((x($_POST,'frontpage')) ? notags(trim($_POST['frontpage'])) : '');
$firstpage = ((x($_POST,'firstpage')) ? notags(trim($_POST['firstpage'])) : 'profiles');
$first_page = ((x($_POST,'first_page')) ? notags(trim($_POST['first_page'])) : 'profiles');
// check value after trim
if(! $firstpage) {
$firstpage = 'profiles';
if(! $first_page) {
$first_page = 'profiles';
}
$mirror_frontpage = ((x($_POST,'mirror_frontpage')) ? intval(trim($_POST['mirror_frontpage'])) : 0);
$directory_server = ((x($_POST,'directory_server')) ? trim($_POST['directory_server']) : '');
@@ -55,6 +56,7 @@ class Site {
$global_directory = ((x($_POST,'directory_submit_url')) ? notags(trim($_POST['directory_submit_url'])) : '');
$no_community_page = !((x($_POST,'no_community_page')) ? True : False);
$default_expire_days = ((array_key_exists('default_expire_days',$_POST)) ? intval($_POST['default_expire_days']) : 0);
$active_expire_days = ((array_key_exists('active_expire_days',$_POST)) ? intval($_POST['active_expire_days']) : 7);
$reply_address = ((array_key_exists('reply_address',$_POST) && trim($_POST['reply_address'])) ? trim($_POST['reply_address']) : 'noreply@' . \App::get_hostname());
$from_email = ((array_key_exists('from_email',$_POST) && trim($_POST['from_email'])) ? trim($_POST['from_email']) : 'Administrator@' . \App::get_hostname());
@@ -86,7 +88,7 @@ class Site {
set_config('system', 'maxloadavg', $maxloadavg);
set_config('system', 'frontpage', $frontpage);
set_config('system', 'sellpage', $site_sellpage);
set_config('system', 'workflow_channel_next', $firstpage);
set_config('system', 'workflow_channel_next', $first_page);
set_config('system', 'site_location', $site_location);
set_config('system', 'mirror_frontpage', $mirror_frontpage);
set_config('system', 'sitename', $sitename);
@@ -94,6 +96,7 @@ class Site {
set_config('system', 'enable_context_help', $enable_context_help);
set_config('system', 'verify_email', $verify_email);
set_config('system', 'default_expire_days', $default_expire_days);
set_config('system', 'active_expire_days', $active_expire_days);
set_config('system', 'reply_address', $reply_address);
set_config('system', 'from_email', $from_email);
set_config('system', 'from_email_name' , $from_email_name);
@@ -347,9 +350,10 @@ class Site {
'$thumbnail_security' => array('thumbnail_security', t("Allow SVG thumbnails in file browser"), get_config('system','thumbnail_security',0), t("WARNING: SVG images may contain malicious code.")),
'$maxloadavg' => array('maxloadavg', t("Maximum Load Average"), ((intval(get_config('system','maxloadavg')) > 0)?get_config('system','maxloadavg'):50), t("Maximum system load before delivery and poll processes are deferred - default 50.")),
'$default_expire_days' => array('default_expire_days', t('Expiration period in days for imported (grid/network) content'), intval(get_config('system','default_expire_days')), t('0 for no expiration of imported content')),
'$active_expire_days' => array('active_expire_days', t('Do not expire any posts which have comments less than this many days ago'), intval(get_config('system','active_expire_days',7)), ''),
'$sellpage' => array('site_sellpage', t('Public servers: Optional landing (marketing) webpage for new registrants'), get_config('system','sellpage',''), sprintf( t('Create this page first. Default is %s/register'),z_root())),
'$firstpage' => array('firstpage', t('Page to display after creating a new channel'), get_config('system','workflow_channel_next','profiles'), t('Recommend: profiles, go, or settings')),
'$first_page' => array('first_page', t('Page to display after creating a new channel'), get_config('system','workflow_channel_next','profiles'), t('Recommend: profiles, go, or settings')),
'$location' => array('site_location', t('Optional: site location'), get_config('system','site_location',''), t('Region or country')),

View File

@@ -25,6 +25,7 @@ class Appman extends \Zotlabs\Web\Controller {
'photo' => escape_tags($_REQUEST['photo']),
'version' => escape_tags($_REQUEST['version']),
'price' => escape_tags($_REQUEST['price']),
'page' => escape_tags($_REQUEST['page']),
'requires' => escape_tags($_REQUEST['requires']),
'system' => intval($_REQUEST['system']),
'plugin' => escape_tags($_REQUEST['plugin']),

View File

@@ -127,21 +127,26 @@ class Articles extends \Zotlabs\Web\Controller {
$editor = '';
}
$itemspage = get_pconfig(local_channel(),'system','itemspage');
\App::set_pager_itemspage(((intval($itemspage)) ? $itemspage : 20));
$pager_sql = sprintf(" LIMIT %d OFFSET %d ", intval(\App::$pager['itemspage']), intval(\App::$pager['start']));
$sql_extra = item_permissions_sql($owner);
$sql_item = '';
if($selected_card) {
$r = q("select * from iconfig where iconfig.cat = 'system' and iconfig.k = 'ARTICLE' and iconfig.v = '%s' limit 1",
dbesc($selected_card)
);
if($r) {
$sql_extra .= "and item.id = " . intval($r[0]['iid']) . " ";
$sql_item = "and item.id = " . intval($r[0]['iid']) . " ";
}
}
$r = q("select * from item
where item.uid = %d and item_type = %d
$sql_extra order by item.created desc",
$sql_extra $sql_item order by item.created desc $pager_sql",
intval($owner),
intval(ITEM_TYPE_ARTICLE)
);
@@ -152,6 +157,8 @@ class Articles extends \Zotlabs\Web\Controller {
if($r) {
$pager_total = count($r);
$parents_str = ids_to_querystr($r,'id');
$items = q("SELECT item.*, item.id AS item_id
@@ -173,13 +180,18 @@ class Articles extends \Zotlabs\Web\Controller {
$mode = 'articles';
$content = conversation($items,$mode,false,'traditional');
if(get_pconfig(local_channel(),'system','articles_list_mode') && (! $selected_card))
$page_mode = 'pager_list';
else
$page_mode = 'traditional';
$content = conversation($items,$mode,false,$page_mode);
$o = replace_macros(get_markup_template('cards.tpl'), [
'$title' => t('Articles'),
'$editor' => $editor,
'$content' => $content,
'$pager' => alt_pager($a,count($items))
'$pager' => alt_pager($pager_total)
]);
return $o;

View File

@@ -4,60 +4,89 @@ namespace Zotlabs\Module;
use Zotlabs\Identity\OAuth2Storage;
class Authorize extends \Zotlabs\Web\Controller {
function init() {
function get() {
if (!local_channel()) {
return login();
} else {
// TODO: Fully implement the dynamic client registration protocol:
// OpenID Connect Dynamic Client Registration 1.0 Client Metadata
// http://openid.net/specs/openid-connect-registration-1_0.html
$app = array(
'name' => (x($_REQUEST, 'client_name') ? urldecode($_REQUEST['client_name']) : t('Unknown App')),
'icon' => (x($_REQUEST, 'logo_uri') ? urldecode($_REQUEST['logo_uri']) : z_root() . '/images/icons/plugin.png'),
'url' => (x($_REQUEST, 'client_uri') ? urldecode($_REQUEST['client_uri']) : ''),
);
$o .= replace_macros(get_markup_template('oauth_authorize.tpl'), array(
'$title' => t('Authorize'),
'$authorize' => sprintf( t('Do you authorize the app %s to access your channel data?'), '<a style="float: none;" href="' . $app['url'] . '">' . $app['name'] . '</a> '),
'$app' => $app,
'$yes' => t('Allow'),
'$no' => t('Deny'),
'$client_id' => (x($_REQUEST, 'client_id') ? $_REQUEST['client_id'] : ''),
'$redirect_uri' => (x($_REQUEST, 'redirect_uri') ? $_REQUEST['redirect_uri'] : ''),
'$state' => (x($_REQUEST, 'state') ? $_REQUEST['state'] : ''),
));
return $o;
}
}
// workaround for HTTP-auth in CGI mode
if (x($_SERVER, 'REDIRECT_REMOTE_USER')) {
$userpass = base64_decode(substr($_SERVER["REDIRECT_REMOTE_USER"], 6)) ;
if(strlen($userpass)) {
list($name, $password) = explode(':', $userpass);
$_SERVER['PHP_AUTH_USER'] = $name;
$_SERVER['PHP_AUTH_PW'] = $password;
}
function post() {
if (! local_channel()) {
return;
}
if (x($_SERVER, 'HTTP_AUTHORIZATION')) {
$userpass = base64_decode(substr($_SERVER["HTTP_AUTHORIZATION"], 6)) ;
if(strlen($userpass)) {
list($name, $password) = explode(':', $userpass);
$_SERVER['PHP_AUTH_USER'] = $name;
$_SERVER['PHP_AUTH_PW'] = $password;
}
}
$storage = new OAuth2Storage(\DBA::$dba->db);
$s = new \Zotlabs\Identity\OAuth2Server($storage);
$s = new \Zotlabs\Identity\OAuth2Server(new OAuth2Storage(\DBA::$dba->db));
// TODO: The automatic client registration protocol below should adhere more
// closely to "OAuth 2.0 Dynamic Client Registration Protocol" defined
// at https://tools.ietf.org/html/rfc7591
// If no client_id was provided, generate a new one.
if (x($_POST, 'client_id')) {
$client_id = $_POST['client_id'];
} else {
$client_id = $_POST['client_id'] = random_string(16);
}
// If no redirect_uri was provided, generate a fake one.
if (x($_POST, 'redirect_uri')) {
$redirect_uri = $_POST['redirect_uri'];
} else {
$redirect_uri = $_POST['redirect_uri'] = 'https://fake.example.com/oauth';
}
$request = \OAuth2\Request::createFromGlobals();
$response = new \OAuth2\Response();
// If the client is not registered, add to the database
if (!$client = $storage->getClientDetails($client_id)) {
$client_secret = random_string(16);
// Client apps are registered per channel
$user_id = local_channel();
$storage->setClientDetails($client_id, $client_secret, $redirect_uri, 'authorization_code', null, $user_id);
}
if (!$client = $storage->getClientDetails($client_id)) {
// There was an error registering the client.
$response->send();
killme();
}
$response->setParameter('client_secret', $client['client_secret']);
// validate the authorize request
if (! $s->validateAuthorizeRequest($request, $response)) {
if (!$s->validateAuthorizeRequest($request, $response)) {
$response->send();
killme();
}
// display an authorization form
if (empty($_POST)) {
return '
<form method="post">
<label>Do You Authorize TestClient?</label><br />
<input type="submit" name="authorized" value="yes">
<input type="submit" name="authorized" value="no">
</form>';
}
// print the authorization code if the user has authorized your client
$is_authorized = ($_POST['authorized'] === 'yes');
$is_authorized = ($_POST['authorize'] === 'allow');
$s->handleAuthorizeRequest($request, $response, $is_authorized, local_channel());
if ($is_authorized) {
// this is only here so that you get to see your code in the cURL request. Otherwise,
// we'd redirect back to the client
$code = substr($response->getHttpHeader('Location'), strpos($response->getHttpHeader('Location'), 'code=')+5, 40);
echo("SUCCESS! Authorization Code: $code");
$code = substr($response->getHttpHeader('Location'), strpos($response->getHttpHeader('Location'), 'code=') + 5, 40);
logger('Authorization Code: ' . $code);
}
$response->send();

View File

@@ -131,20 +131,26 @@ class Cards extends \Zotlabs\Web\Controller {
}
$itemspage = get_pconfig(local_channel(),'system','itemspage');
\App::set_pager_itemspage(((intval($itemspage)) ? $itemspage : 20));
$pager_sql = sprintf(" LIMIT %d OFFSET %d ", intval(\App::$pager['itemspage']), intval(\App::$pager['start']));
$sql_extra = item_permissions_sql($owner);
$sql_item = '';
if($selected_card) {
$r = q("select * from iconfig where iconfig.cat = 'system' and iconfig.k = 'CARD' and iconfig.v = '%s' limit 1",
dbesc($selected_card)
);
if($r) {
$sql_extra .= "and item.id = " . intval($r[0]['iid']) . " ";
$sql_item = "and item.id = " . intval($r[0]['iid']) . " ";
}
}
$r = q("select * from item
where uid = %d and item_type = %d
$sql_extra order by item.created desc",
$sql_extra $sql_item order by item.created desc $pager_sql",
intval($owner),
intval(ITEM_TYPE_CARD)
);
@@ -156,6 +162,8 @@ class Cards extends \Zotlabs\Web\Controller {
$items_result = [];
if($r) {
$pager_total = count($r);
$parents_str = ids_to_querystr($r, 'id');
$items = q("SELECT item.*, item.id AS item_id
@@ -175,13 +183,18 @@ class Cards extends \Zotlabs\Web\Controller {
$mode = 'cards';
$content = conversation($items_result, $mode, false, 'traditional');
if(get_pconfig(local_channel(),'system','articles_list_mode') && (! $selected_card))
$page_mode = 'pager_list';
else
$page_mode = 'traditional';
$content = conversation($items_result, $mode, false, $page_mode);
$o = replace_macros(get_markup_template('cards.tpl'), [
'$title' => t('Cards'),
'$editor' => $editor,
'$content' => $content,
'$pager' => alt_pager($a, count($items_result))
'$pager' => alt_pager($pager_total)
]);
return $o;

View File

@@ -204,7 +204,7 @@ class Channel extends \Zotlabs\Web\Controller {
$_SESSION['loadtime'] = datetime_convert();
}
else {
$r = q("SELECT distinct parent AS item_id from item
$r = q("SELECT parent AS item_id from item
left join abook on ( item.owner_xchan = abook.abook_xchan $abook_uids )
WHERE uid = %d $item_normal_update
AND item_wall = 1 $simple_update
@@ -312,8 +312,8 @@ class Channel extends \Zotlabs\Web\Controller {
'$uid' => ((\App::$profile['profile_uid']) ? \App::$profile['profile_uid'] : '0'),
'$gid' => '0',
'$cid' => '0',
'$cmin' => '0',
'$cmax' => '0',
'$cmin' => '(-1)',
'$cmax' => '(-1)',
'$star' => '0',
'$liked' => '0',
'$conv' => '0',
@@ -380,7 +380,7 @@ class Channel extends \Zotlabs\Web\Controller {
}
if((! $update) || ($checkjs->disabled())) {
$o .= alt_pager($a,count($items));
$o .= alt_pager(count($items));
if ($mid && $items[0]['title'])
\App::$page['title'] = $items[0]['title'] . " - " . \App::$page['title'];
}

View File

@@ -19,7 +19,7 @@ class Chanview extends \Zotlabs\Web\Controller {
}
if($_REQUEST['address']) {
$r = q("select * from xchan where xchan_addr = '%s' limit 1",
dbesc($_REQUEST['address'])
dbesc(punify($_REQUEST['address']))
);
}
elseif(local_channel() && intval($_REQUEST['cid'])) {

View File

@@ -60,7 +60,7 @@ class Chatsvc extends \Zotlabs\Web\Controller {
intval(\App::$data['chat']['room_id']),
dbesc(get_observer_hash()),
dbesc(datetime_convert()),
dbesc($arr['chat_text'])
dbesc(str_rot47(base64url_encode($arr['chat_text'])))
);
$ret['success'] = true;
@@ -157,7 +157,7 @@ class Chatsvc extends \Zotlabs\Web\Controller {
'name' => $rr['xchan_name'],
'isotime' => datetime_convert('UTC', date_default_timezone_get(), $rr['created'], 'c'),
'localtime' => datetime_convert('UTC', date_default_timezone_get(), $rr['created'], 'r'),
'text' => zidify_links(smilies(bbcode($rr['chat_text']))),
'text' => zidify_links(smilies(bbcode(base64url_decode(str_rot47($rr['chat_text']))))),
'self' => ((get_observer_hash() == $rr['chat_xchan']) ? 'self' : '')
);
}

View File

@@ -60,6 +60,12 @@ class Cloud extends \Zotlabs\Web\Controller {
// if we arrived at this path with any query parameters in the url, build a clean url without
// them and redirect.
if(! array_key_exists('cloud_sort',$_SESSION)) {
$_SESSION['cloud_sort'] = 'name';
}
$_SESSION['cloud_sort'] = (($_REQUEST['sort']) ? trim(notags($_REQUEST['sort'])) : $_SESSION['cloud_sort']);
$x = clean_query_string();
if($x !== \App::$query_string)
goaway(z_root() . '/' . $x);

View File

@@ -32,6 +32,7 @@ class Connections extends \Zotlabs\Web\Controller {
nav_set_selected('Connections');
$active = false;
$blocked = false;
$hidden = false;
$ignored = false;
@@ -44,11 +45,16 @@ class Connections extends \Zotlabs\Web\Controller {
if(! $_REQUEST['aj'])
$_SESSION['return_url'] = \App::$query_string;
$search_flags = '';
$search_flags = "";
$head = '';
if(argc() == 2) {
switch(argv(1)) {
case 'active':
$search_flags = " and abook_blocked = 0 and abook_ignored = 0 and abook_hidden = 0 and abook_archived = 0 AND abook_not_here = 0 ";
$head = t('Active');
$active = true;
break;
case 'blocked':
$search_flags = " and abook_blocked = 1 ";
$head = t('Blocked');
@@ -101,8 +107,9 @@ class Connections extends \Zotlabs\Web\Controller {
case 'all':
$head = t('All');
default:
$search_flags = '';
$all = true;
$search_flags = " and abook_blocked = 0 and abook_ignored = 0 and abook_hidden = 0 and abook_archived = 0 and abook_not_here = 0 ";
$active = true;
$head = t('Active');
break;
}
@@ -129,6 +136,13 @@ class Connections extends \Zotlabs\Web\Controller {
),
*/
'active' => array(
'label' => t('Active Connections'),
'url' => z_root() . '/connections/active',
'sel' => ($active) ? 'active' : '',
'title' => t('Show active connections'),
),
'pending' => array(
'label' => t('New Connections'),
'url' => z_root() . '/connections/pending',
@@ -136,12 +150,6 @@ class Connections extends \Zotlabs\Web\Controller {
'title' => t('Show pending (new) connections'),
),
'all' => array(
'label' => t('All Connections'),
'url' => z_root() . '/connections/all',
'sel' => ($all) ? 'active' : '',
'title' => t('Show all connections'),
),
/*
array(
@@ -187,6 +195,13 @@ class Connections extends \Zotlabs\Web\Controller {
// 'title' => t('Only show one-way connections'),
// ),
'all' => array(
'label' => t('All Connections'),
'url' => z_root() . '/connections',
'sel' => ($all) ? 'active' : '',
'title' => t('Show all connections'),
),
);
@@ -238,6 +253,7 @@ class Connections extends \Zotlabs\Web\Controller {
$status_str = '';
$status = array(
((intval($rr['abook_active'])) ? t('Active') : ''),
((intval($rr['abook_pending'])) ? t('Pending approval') : ''),
((intval($rr['abook_archived'])) ? t('Archived') : ''),
((intval($rr['abook_hidden'])) ? t('Hidden') : ''),
@@ -310,7 +326,7 @@ class Connections extends \Zotlabs\Web\Controller {
killme();
}
else {
$o .= "<script> var page_query = '" . $_GET['q'] . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$o .= "<script> var page_query = '" . escape_tags($_GET['q']) . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$o .= replace_macros(get_markup_template('connections.tpl'),array(
'$header' => t('Connections') . (($head) ? ': ' . $head : ''),
'$tabs' => $tabs,

View File

@@ -828,7 +828,7 @@ class Connedit extends \Zotlabs\Web\Controller {
$locstr = locations_by_netid($contact['xchan_hash']);
if(! $locstr)
$locstr = $contact['xchan_url'];
$locstr = unpunify($contact['xchan_url']);
$clone_warn = '';
$clonable = (in_array($contact['xchan_network'],['zot','rss']) ? true : false);
@@ -852,8 +852,8 @@ class Connedit extends \Zotlabs\Web\Controller {
'$permcat' => [ 'permcat', t('Permission role'), '', '<span class="loading invisible">' . t('Loading') . '<span class="jumping-dots"><span class="dot-1">.</span><span class="dot-2">.</span><span class="dot-3">.</span></span></span>',$permcats ],
'$permcat_new' => t('Add permission role'),
'$permcat_enable' => feature_enabled(local_channel(),'permcats'),
'$addr' => $contact['xchan_addr'],
'$primeurl' => $contact['xchan_url'],
'$addr' => unpunify($contact['xchan_addr']),
'$primeurl' => unpunify($contact['xchan_url']),
'$section' => $section,
'$sections' => $sections,
'$vcard' => $vcard,

View File

@@ -355,6 +355,8 @@ class Cover_photo extends \Zotlabs\Web\Controller {
$o .= replace_macros($tpl,array(
'$user' => \App::$channel['channel_address'],
'$info' => t('Your cover photo may be visible to anybody on the internet'),
'$existing' => get_cover_photo(local_channel(),'array',PHOTO_RES_COVER_850),
'$lbl_upfile' => t('Upload File:'),
'$lbl_profiles' => t('Select a profile:'),
'$title' => t('Change Cover Photo'),

View File

@@ -299,9 +299,9 @@ class Directory extends \Zotlabs\Web\Controller {
if(strlen($out))
$out .= ', ';
if($marr && in_arrayi($k,$marr))
$out .= '<strong>' . $k . '</strong>';
$out .= '<a href="' . z_root() . '/directory/f=&keywords=' . urlencode($k) .'"><strong>' . $k . '</strong></a>';
else
$out .= $k;
$out .= '<a href="' . z_root() . '/directory/f=&keywords=' . urlencode($k) .'">' . $k . '</a>';
}
}
@@ -395,7 +395,7 @@ class Directory extends \Zotlabs\Web\Controller {
$dirtitle = (($globaldir) ? t('Global Directory') : t('Local Directory'));
$o .= "<script> var page_query = '" . $_GET['q'] . "'; var extra_args = '" . extra_query_args() . "' ; divmore_height = " . intval($maxheight) . "; </script>";
$o .= "<script> var page_query = '" . escape_tags($_GET['q']) . "'; var extra_args = '" . extra_query_args() . "' ; divmore_height = " . intval($maxheight) . "; </script>";
$o .= replace_macros($tpl, array(
'$search' => $search,
'$desc' => t('Find'),
@@ -404,7 +404,7 @@ class Directory extends \Zotlabs\Web\Controller {
'$entries' => $entries,
'$dirlbl' => $suggest ? t('Channel Suggestions') : $dirtitle,
'$submit' => t('Find'),
'$next' => alt_pager($a,$j['records'], t('next page'), t('previous page')),
'$next' => alt_pager($j['records'], t('next page'), t('previous page')),
'$sort' => t('Sort options'),
'$normal' => t('Alphabetic'),
'$reverse' => t('Reverse Alphabetic'),

View File

@@ -102,7 +102,7 @@ class Display extends \Zotlabs\Web\Controller {
if($decoded)
$item_hash = $decoded;
$r = q("select id, uid, mid, parent_mid, thr_parent, verb, item_type, item_deleted, item_blocked from item where mid like '%s' limit 1",
$r = q("select id, uid, mid, parent_mid, thr_parent, verb, item_type, item_deleted, author_xchan, item_blocked from item where mid like '%s' limit 1",
dbesc($item_hash . '%')
);
@@ -110,6 +110,14 @@ class Display extends \Zotlabs\Web\Controller {
$target_item = $r[0];
}
$x = q("select * from xchan where xchan_hash = '%s' limit 1",
dbesc($target_item['author_xchan'])
);
if($x) {
// not yet ready for prime time
// \App::$poi = $x[0];
}
//if the item is to be moderated redirect to /moderate
if($target_item['item_blocked'] == ITEM_MODERATED) {
goaway(z_root() . '/moderate/' . $target_item['id']);
@@ -124,7 +132,7 @@ class Display extends \Zotlabs\Web\Controller {
$y = q("select * from iconfig left join item on iconfig.iid = item.id
where item.uid = %d and iconfig.cat = 'system' and iconfig.k = 'WEBPAGE' and item.id = %d limit 1",
intval($target_item['uid']),
intval($target_item['id'])
intval($target_item['parent'])
);
if($x && $y) {
goaway(z_root() . '/page/' . $x[0]['channel_address'] . '/' . $y[0]['v']);
@@ -134,6 +142,41 @@ class Display extends \Zotlabs\Web\Controller {
return '';
}
}
if($target_item['item_type'] == ITEM_TYPE_ARTICLE) {
$x = q("select * from channel where channel_id = %d limit 1",
intval($target_item['uid'])
);
$y = q("select * from iconfig left join item on iconfig.iid = item.id
where item.uid = %d and iconfig.cat = 'system' and iconfig.k = 'ARTICLE' and item.id = %d limit 1",
intval($target_item['uid']),
intval($target_item['parent'])
);
if($x && $y) {
goaway(z_root() . '/articles/' . $x[0]['channel_address'] . '/' . $y[0]['v']);
}
else {
notice( t('Page not found.') . EOL);
return '';
}
}
if($target_item['item_type'] == ITEM_TYPE_CARD) {
$x = q("select * from channel where channel_id = %d limit 1",
intval($target_item['uid'])
);
$y = q("select * from iconfig left join item on iconfig.iid = item.id
where item.uid = %d and iconfig.cat = 'system' and iconfig.k = 'CARD' and item.id = %d limit 1",
intval($target_item['uid']),
intval($target_item['parent'])
);
if($x && $y) {
goaway(z_root() . '/cards/' . $x[0]['channel_address'] . '/' . $y[0]['v']);
}
else {
notice( t('Page not found.') . EOL);
return '';
}
}
$static = ((array_key_exists('static',$_REQUEST)) ? intval($_REQUEST['static']) : 0);
@@ -170,8 +213,8 @@ class Display extends \Zotlabs\Web\Controller {
'$uid' => '0',
'$gid' => '0',
'$cid' => '0',
'$cmin' => '0',
'$cmax' => '99',
'$cmin' => '(-1)',
'$cmax' => '(-1)',
'$star' => '0',
'$liked' => '0',
'$conv' => '0',

View File

@@ -82,7 +82,7 @@ class Editpost extends \Zotlabs\Web\Controller {
'editor_autocomplete'=> true,
'bbco_autocomplete'=> 'bbcode',
'return_path' => $_SESSION['return_url'],
'button' => t('Edit'),
'button' => t('Submit'),
'hide_voting' => true,
'hide_future' => true,
'hide_location' => true,

View File

@@ -14,21 +14,26 @@ class Follow extends \Zotlabs\Web\Controller {
}
$uid = local_channel();
$url = notags(trim($_REQUEST['url']));
$url = notags(trim(punify($_REQUEST['url'])));
$return_url = $_SESSION['return_url'];
$confirm = intval($_REQUEST['confirm']);
$interactive = (($_REQUEST['interactive']) ? intval($_REQUEST['interactive']) : 1);
$channel = \App::get_channel();
$result = new_contact($uid,$url,$channel,true,$confirm);
$result = new_contact($uid,$url,$channel,$interactive,$confirm);
if($result['success'] == false) {
if($result['message'])
notice($result['message']);
goaway($return_url);
if($interactive) {
goaway($return_url);
}
else {
json_return_and_die($result);
}
}
info( t('Channel added.') . EOL);
info( t('Connection added.') . EOL);
$clone = array();
foreach($result['abook'] as $k => $v) {
@@ -53,7 +58,12 @@ class Follow extends \Zotlabs\Web\Controller {
if(($can_view_stream) || ($result['abook']['xchan_network'] === 'rss'))
\Zotlabs\Daemon\Master::Summon(array('Onepoll',$result['abook']['abook_id']));
goaway(z_root() . '/connedit/' . $result['abook']['abook_id'] . '?f=&follow=1');
if($interactive) {
goaway(z_root() . '/connedit/' . $result['abook']['abook_id'] . '?f=&follow=1');
}
else {
json_return_and_die([ 'success' => true ]);
}
}

View File

@@ -0,0 +1,27 @@
<?php
namespace Zotlabs\Module;
class Hashtags extends \Zotlabs\Web\Controller {
function init() {
$result = [];
$t = escape_tags($_REQUEST['t']);
if(! $t)
json_return_and_die($result);
$r = q("select distinct(term) from term where term like '%s' and ttype = %d order by term",
dbesc($t . '%'),
intval(TERM_HASHTAG)
);
if($r) {
foreach($r as $rv) {
$result[] = [ 'text' => $rv['term'] ];
}
}
json_return_and_die($result);
}
}

View File

@@ -114,15 +114,16 @@ class Import extends \Zotlabs\Web\Controller {
return;
}
if(array_key_exists('compatibility',$data) && array_key_exists('database',$data['compatibility'])) {
$v1 = substr($data['compatibility']['database'],-4);
$v2 = substr(DB_UPDATE_VERSION,-4);
if($v2 > $v1) {
$t = sprintf( t('Warning: Database versions differ by %1$d updates.'), $v2 - $v1 );
notice($t);
}
}
// This is only an info message but it is alarming to folks who then report failure with this as the cause, when in fact we ignore this completely.
// if(array_key_exists('compatibility',$data) && array_key_exists('database',$data['compatibility'])) {
// $v1 = substr($data['compatibility']['database'],-4);
// $v2 = substr(DB_UPDATE_VERSION,-4);
// if($v2 > $v1) {
// $t = sprintf( t('Warning: Database versions differ by %1$d updates.'), $v2 - $v1 );
// notice($t);
// }
//
// }
if($moving)
$seize = 1;
@@ -362,11 +363,27 @@ class Import extends \Zotlabs\Web\Controller {
continue;
}
abook_store_lowlevel($abook);
$r = q("select abook_id from abook where abook_xchan = '%s' and abook_channel = %d limit 1",
dbesc($abook['abook_xchan']),
intval($channel['channel_id'])
);
if($r) {
foreach($abook as $k => $v) {
$r = q("UPDATE abook SET " . TQUOT . "%s" . TQUOT . " = '%s' WHERE abook_xchan = '%s' AND abook_channel = %d",
dbesc($k),
dbesc($v),
dbesc($abook['abook_xchan']),
intval($channel['channel_id'])
);
}
}
else {
abook_store_lowlevel($abook);
$friends ++;
if(intval($abook['abook_feed']))
$feeds ++;
$friends ++;
if(intval($abook['abook_feed']))
$feeds ++;
}
translate_abook_perms_inbound($channel,$abook_copy);
@@ -515,16 +532,19 @@ class Import extends \Zotlabs\Web\Controller {
'$desc' => t('Use this form to import an existing channel from a different server/hub. You may retrieve the channel identity from the old server/hub via the network or provide an export file.'),
'$label_filename' => t('File to Upload'),
'$choice' => t('Or provide the old server/hub details'),
'$label_old_address' => t('Your old identity address (xyz@example.com)'),
'$label_old_email' => t('Your old login email address'),
'$label_old_pass' => t('Your old login password'),
'$old_address' => [ 'old_address', t('Your old identity address (xyz@example.com)'), '', ''],
'$email' => [ 'email', t('Your old login email address'), '', '' ],
'$password' => [ 'password', t('Your old login password'), '', '' ],
'$import_posts' => [ 'import_posts', t('Import a few months of posts if possible (limited by available memory'), false, '', [ t('No'), t('Yes') ]],
'$common' => t('For either option, please choose whether to make this hub your new primary address, or whether your old location should continue this role. You will be able to post from either location, but only one can be marked as the primary location for files, photos, and media.'),
'$label_import_primary' => t('Make this hub my primary location'),
'$label_import_moving' => t('Move this channel (disable all previous locations)'),
'$label_import_posts' => t('Import a few months of posts if possible (limited by available memory'),
'$make_primary' => [ 'make_primary', t('Make this hub my primary location'), false, '', [ t('No'), t('Yes') ] ],
'$moving' => [ 'moving', t('Move this channel (disable all previous locations)'), false, '', [ t('No'), t('Yes') ] ],
'$pleasewait' => t('This process may take several minutes to complete. Please submit the form only once and leave this page open until finished.'),
'$email' => '',
'$pass' => '',
'$form_security_token' => get_form_security_token('channel_import'),
'$submit' => t('Submit')
));

View File

@@ -468,6 +468,7 @@ class Item extends \Zotlabs\Web\Controller {
$private = intval($acl->is_private() || $parent_item['item_private']);
$public_policy = $parent_item['public_policy'];
$owner_hash = $parent_item['owner_xchan'];
$webpage = $parent_item['item_type'];
}
if((! $allow_empty) && (! strlen($body))) {
@@ -542,7 +543,7 @@ class Item extends \Zotlabs\Web\Controller {
// Look for tags and linkify them
$results = linkify_tags($a, $body, ($uid) ? $uid : $profile_uid);
if($results) {
// Set permissions based on tag replacements

View File

@@ -296,10 +296,11 @@ class Like extends \Zotlabs\Web\Controller {
notice( t('Permission denied') . EOL);
killme();
}
$r = q("select * from xchan where xchan_hash = '%s' limit 1",
dbesc($item['owner_xchan'])
);
if($r)
$thread_owner = $r[0];
else
@@ -418,6 +419,7 @@ class Like extends \Zotlabs\Web\Controller {
$arr['item_origin'] = 1;
$arr['item_notshown'] = 1;
$arr['item_type'] = $item['item_type'];
if(intval($item['item_wall']))
$arr['item_wall'] = 1;

View File

@@ -5,7 +5,12 @@ namespace Zotlabs\Module;
class Logout extends \Zotlabs\Web\Controller {
function init() {
\App::$session->nuke();
if($_SESSION['delegate'] && $_SESSION['delegate_push']) {
$_SESSION = $_SESSION['delegate_push'];
}
else {
\App::$session->nuke();
}
goaway(z_root());
}

View File

@@ -14,12 +14,18 @@ class Magic extends \Zotlabs\Web\Controller {
logger('mod_magic: args: ' . print_r($_REQUEST,true),LOGGER_DATA);
$addr = ((x($_REQUEST,'addr')) ? $_REQUEST['addr'] : '');
$bdest = ((x($_REQUEST,'bdest')) ? $_REQUEST['bdest'] : '');
$dest = ((x($_REQUEST,'dest')) ? $_REQUEST['dest'] : '');
$test = ((x($_REQUEST,'test')) ? intval($_REQUEST['test']) : 0);
$rev = ((x($_REQUEST,'rev')) ? intval($_REQUEST['rev']) : 0);
$owa = ((x($_REQUEST,'owa')) ? intval($_REQUEST['owa']) : 0);
$delegate = ((x($_REQUEST,'delegate')) ? $_REQUEST['delegate'] : '');
if($bdest)
$dest = hex2bin($bdest);
$dest = html_entity_decode($dest);
$parsed = parse_url($dest);
if(! $parsed) {
if($test) {
@@ -112,6 +118,8 @@ class Magic extends \Zotlabs\Web\Controller {
if($r && intval($r[0]['channel_id'])) {
$allowed = perm_is_allowed($r[0]['channel_id'],get_observer_hash(),'delegate');
if($allowed) {
$tmp = $_SESSION;
$_SESSION['delegate_push'] = $tmp;
$_SESSION['delegate_channel'] = $r[0]['channel_id'];
$_SESSION['delegate'] = get_observer_hash();
$_SESSION['account_id'] = intval($r[0]['channel_account_id']);

View File

@@ -67,14 +67,14 @@ class Mail extends \Zotlabs\Web\Controller {
if(! $recipient) {
$channel = \App::get_channel();
$j = \Zotlabs\Zot\Finger::run($rstr,$channel);
$j = \Zotlabs\Zot\Finger::run(punify($rstr),$channel);
if(! $j['success']) {
notice( t('Unable to lookup recipient.') . EOL);
return;
}
logger('message_post: lookup: ' . $url . ' ' . print_r($j,true));
logger('message_post: lookup: ' . $rstr . ' ' . print_r($j,true));
if(! $j['guid']) {
notice( t('Unable to communicate with requested channel.'));

View File

@@ -93,7 +93,7 @@ class Message extends \Zotlabs\Web\Controller {
));
$o .= alt_pager($a,count($r));
$o .= alt_pager(count($r));
return $o;

View File

@@ -14,9 +14,12 @@ class Moderate extends \Zotlabs\Web\Controller {
return;
}
\App::set_pager_itemspage(60);
$pager_sql = sprintf(" LIMIT %d OFFSET %d ", intval(\App::$pager['itemspage']), intval(\App::$pager['start']));
//show all items
if(argc() == 1) {
$r = q("select item.id as item_id, item.* from item where item.uid = %d and item_blocked = %d and item_deleted = 0 order by created desc limit 60",
$r = q("select item.id as item_id, item.* from item where item.uid = %d and item_blocked = %d and item_deleted = 0 order by created desc $pager_sql",
intval(local_channel()),
intval(ITEM_MODERATED)
);
@@ -26,7 +29,7 @@ class Moderate extends \Zotlabs\Web\Controller {
if(argc() == 2) {
$post_id = intval(argv(1));
$r = q("select item.id as item_id, item.* from item where item.id = %d and item.uid = %d and item_blocked = %d and item_deleted = 0 order by created desc limit 60",
$r = q("select item.id as item_id, item.* from item where item.id = %d and item.uid = %d and item_blocked = %d and item_deleted = 0 order by created desc $pager_sql",
intval($post_id),
intval(local_channel()),
intval(ITEM_MODERATED)
@@ -47,17 +50,26 @@ class Moderate extends \Zotlabs\Web\Controller {
);
if($r) {
$item = $r[0];
if($action === 'approve') {
q("update item set item_blocked = 0 where uid = %d and id = %d",
intval(local_channel()),
intval($post_id)
);
$item['item_blocked'] = 0;
item_update_parent_commented($item);
notice( t('Comment approved') . EOL);
}
elseif($action === 'drop') {
drop_item($post_id,false);
notice( t('Comment deleted') . EOL);
}
// refetch the item after changes have been made
$r = q("select * from item where id = %d",
intval($post_id)
@@ -83,6 +95,7 @@ class Moderate extends \Zotlabs\Web\Controller {
}
$o = conversation($items,'moderate',false,'traditional');
$o .= alt_pager(count($items));
return $o;
}

View File

@@ -107,9 +107,8 @@ class Network extends \Zotlabs\Web\Controller {
$def_acl = array('allow_gid' => '<' . $r[0]['hash'] . '>');
}
$default_cmin = ((feature_enabled(local_channel(),'affinity')) ? get_pconfig(local_channel(),'affinity','cmin',0) : 0);
$default_cmax = ((feature_enabled(local_channel(),'affinity')) ? get_pconfig(local_channel(),'affinity','cmax',99) : 99);
$default_cmin = ((feature_enabled(local_channel(),'affinity')) ? get_pconfig(local_channel(),'affinity','cmin',0) : (-1));
$default_cmax = ((feature_enabled(local_channel(),'affinity')) ? get_pconfig(local_channel(),'affinity','cmax',99) : (-1));
// if no tabs are selected, defaults to comments
@@ -130,6 +129,7 @@ class Network extends \Zotlabs\Web\Controller {
if(x($_GET,'search') || x($_GET,'file'))
$nouveau = true;
if($cid) {
$r = q("SELECT abook_xchan FROM abook WHERE abook_id = %d AND abook_channel = %d LIMIT 1",
intval($cid),
@@ -210,10 +210,9 @@ class Network extends \Zotlabs\Web\Controller {
$sql_nets = '';
$distinct = '';
$item_thread_top = ' AND item_thread_top = 1 ';
$sql_extra = $sql_options;
$sql_extra = '';
if($group) {
$contact_str = '';
@@ -229,7 +228,6 @@ class Network extends \Zotlabs\Web\Controller {
$contact_str = ' 0 ';
info( t('Privacy group is empty'));
}
$distinct = ' distinct ';
$item_thread_top = '';
$sql_extra = " AND item.parent IN ( SELECT DISTINCT parent FROM item WHERE true $sql_options AND (( author_xchan IN ( $contact_str ) OR owner_xchan in ( $contact_str )) or allow_gid like '" . protect_sprintf('%<' . dbesc($group_hash) . '>%') . "' ) and id = parent $item_normal ) ";
@@ -254,7 +252,6 @@ class Network extends \Zotlabs\Web\Controller {
intval(local_channel())
);
if($r) {
$distinct = ' distinct ';
$item_thread_top = '';
$sql_extra = " AND item.parent IN ( SELECT DISTINCT parent FROM item WHERE true $sql_options AND uid = " . intval(local_channel()) . " AND ( author_xchan = '" . dbesc($r[0]['abook_xchan']) . "' or owner_xchan = '" . dbesc($r[0]['abook_xchan']) . "' ) $item_normal ) ";
$title = replace_macros(get_markup_template("section_title.tpl"),array(
@@ -274,7 +271,6 @@ class Network extends \Zotlabs\Web\Controller {
dbesc($xchan)
);
if($r) {
$distinct = ' distinct ';
$item_thread_top = '';
$sql_extra = " AND item.parent IN ( SELECT DISTINCT parent FROM item WHERE true $sql_options AND uid = " . intval(local_channel()) . " AND ( author_xchan = '" . dbesc($xchan) . "' or owner_xchan = '" . dbesc($xchan) . "' ) $item_normal ) ";
$title = replace_macros(get_markup_template("section_title.tpl"),array(
@@ -320,8 +316,8 @@ class Network extends \Zotlabs\Web\Controller {
'$uid' => ((local_channel()) ? local_channel() : '0'),
'$gid' => (($gid) ? $gid : '0'),
'$cid' => (($cid) ? $cid : '0'),
'$cmin' => (($cmin) ? $cmin : '0'),
'$cmax' => (($cmax) ? $cmax : '0'),
'$cmin' => (($cmin) ? $cmin : '(-1)'),
'$cmax' => (($cmax) ? $cmax : '(-1)'),
'$star' => (($star) ? $star : '0'),
'$liked' => (($liked) ? $liked : '0'),
'$conv' => (($conv) ? $conv : '0'),
@@ -381,7 +377,6 @@ class Network extends \Zotlabs\Web\Controller {
}
if($conv) {
$distinct = ' distinct ';
$item_thread_top = '';
$sql_extra .= sprintf(" AND parent IN (SELECT distinct(parent) from item where ( author_xchan like '%s' or item_mentionsme = 1 )) ",
dbesc(protect_sprintf($channel['channel_hash']))
@@ -400,8 +395,9 @@ class Network extends \Zotlabs\Web\Controller {
$pager_sql = sprintf(" LIMIT %d OFFSET %d ", intval(\App::$pager['itemspage']), intval(\App::$pager['start']));
}
if(($cmin != 0) || ($cmax != 99)) {
// cmin and cmax are both -1 when the affinity tool is disabled
if(($cmin != (-1)) || ($cmax != (-1))) {
// Not everybody who shows up in the network stream will be in your address book.
// By default those that aren't are assumed to have closeness = 99; but this isn't
@@ -464,7 +460,7 @@ class Network extends \Zotlabs\Web\Controller {
WHERE true $uids $item_normal
and (abook.abook_blocked = 0 or abook.abook_flags is null)
$simple_update
$sql_extra $sql_nets
$sql_extra $sql_options $sql_nets
$net_query2
ORDER BY item.received DESC $pager_sql "
);
@@ -487,13 +483,13 @@ class Network extends \Zotlabs\Web\Controller {
if($load) {
// Fetch a page full of parent items for this page
$r = q("SELECT $distinct item.parent AS item_id FROM item
$r = q("SELECT item.parent AS item_id FROM item
left join abook on ( item.owner_xchan = abook.abook_xchan $abook_uids )
$net_query
WHERE true $uids $item_thread_top $item_normal
AND item.mid = item.parent_mid
and (abook.abook_blocked = 0 or abook.abook_flags is null)
$sql_extra3 $sql_extra $sql_nets
$sql_extra3 $sql_extra $sql_options $sql_nets
$net_query2
ORDER BY $ordering DESC $pager_sql "
);
@@ -506,7 +502,7 @@ class Network extends \Zotlabs\Web\Controller {
$net_query
WHERE true $uids $item_normal_update $simple_update
and (abook.abook_blocked = 0 or abook.abook_flags is null)
$sql_extra3 $sql_extra $sql_nets $net_query2"
$sql_extra3 $sql_extra $sql_options $sql_nets $net_query2"
);
$_SESSION['loadtime'] = datetime_convert();
}
@@ -570,7 +566,7 @@ class Network extends \Zotlabs\Web\Controller {
$o .= conversation($items,$mode,$update,$page_mode);
if(($items) && (! $update))
$o .= alt_pager($a,count($items));
$o .= alt_pager(count($items));
return $o;
}

View File

@@ -16,8 +16,15 @@ class New_channel extends \Zotlabs\Web\Controller {
require_once('library/urlify/URLify.php');
$result = array('error' => false, 'message' => '');
$n = trim($_REQUEST['name']);
$x = strtolower(\URLify::transliterate($n));
$x = false;
if(get_config('system','unicode_usernames')) {
$x = punify(mb_strtolower($n));
}
if((! $x) || strlen($x) > 64)
$x = strtolower(\URLify::transliterate($n));
$test = array();
@@ -43,7 +50,14 @@ class New_channel extends \Zotlabs\Web\Controller {
$result = array('error' => false, 'message' => '');
$n = trim($_REQUEST['nick']);
$x = strtolower(\URLify::transliterate($n));
$x = false;
if(get_config('system','unicode_usernames')) {
$x = punify(mb_strtolower($n));
}
if((! $x) || strlen($x) > 64)
$x = strtolower(\URLify::transliterate($n));
$test = array();
@@ -132,14 +146,14 @@ class New_channel extends \Zotlabs\Web\Controller {
$name = array('name', t('Name or caption'), ((x($_REQUEST,'name')) ? $_REQUEST['name'] : ''), t('Examples: "Bob Jameson", "Lisa and her Horses", "Soccer", "Aviation Group"'), "*");
$nickhub = '@' . \App::get_hostname();
$nickname = array('nickname', t('Choose a short nickname'), ((x($_REQUEST,'nickname')) ? $_REQUEST['nickname'] : ''), sprintf( t('Your nickname will be used to create an easy to remember channel address e.g. nickname%s'), $nickhub), "*");
$role = array('permissions_role' , t('Channel role and privacy'), ($privacy_role) ? $privacy_role : 'social', t('Select a channel role with your privacy requirements.') . ' <a href="help/member/member_guide#Account_Permission_Roles" target="_blank">' . t('Read more about roles') . '</a>',$perm_roles);
$role = array('permissions_role' , t('Channel role and privacy'), ($privacy_role) ? $privacy_role : 'social', t('Select a channel role with your privacy requirements.') . ' <a href="help/member/member_guide#Channel_Permission_Roles" target="_blank">' . t('Read more about roles') . '</a>',$perm_roles);
$o = replace_macros(get_markup_template('new_channel.tpl'), array(
'$title' => t('Create Channel'),
'$desc' => t('A channel is your identity on this network. It can represent a person, a blog, or a forum to name a few. Channels can make connections with other channels to share information with highly detailed permissions.'),
'$desc' => t('A channel is a unique network identity. It can represent a person (social network profile), a forum (group), a business or celebrity page, a newsfeed, and many other things. Channels can make connections with other channels to share information with each other.') . ' ' . t('The type of channel you create affects the basic privacy settings, the permissions that are granted to connections/friends, and also the channel\'s visibility across the network.'),
'$label_import' => t('or <a href="import">import an existing channel</a> from another location.'),
'$name' => $name,
'$role' => $role,
'$role' => $role,
'$default_role' => $default_role,
'$nickname' => $nickname,
'$validate' => t('Validate'),

View File

@@ -0,0 +1,151 @@
<?php
namespace Zotlabs\Module;
/**
* The OAuth2TestVehicle class is a way to test the registration of an OAuth2
* client app. It allows you to walk through the steps of registering a client,
* requesting an authorization code for that client, and then requesting an
* access token for use in authentication against the Hubzilla API endpoints.
*/
class OAuth2TestVehicle extends \Zotlabs\Web\Controller {
function init() {
killme();
// If there is a 'code' and 'state' parameter then this is a client app
// callback issued after the authorization code request
// TODO: Check state value and compare to original sent value
// "You should first compare this state value to ensure it matches the
// one you started with. You can typically store the state value in a
// cookie, and compare it when the user comes back. This ensures your
// redirection endpoint isn't able to be tricked into attempting to
// exchange arbitrary authorization codes."
$_SESSION['redirect_uri'] = z_root() . '/oauth2testvehicle';
$_SESSION['authorization_code'] = (x($_REQUEST, 'code') ? $_REQUEST['code'] : $_SESSION['authorization_code']);
$_SESSION['state'] = (x($_REQUEST, 'state') ? $_REQUEST['state'] : $_SESSION['state'] );
$_SESSION['client_id'] = (x($_REQUEST, 'client_id') ? $_REQUEST['client_id'] : $_SESSION['client_id'] );
$_SESSION['client_secret'] = (x($_REQUEST, 'client_secret') ? $_REQUEST['client_secret'] : $_SESSION['client_secret']);
$_SESSION['access_token'] = (x($_REQUEST, 'access_token') ? $_REQUEST['access_token'] : $_SESSION['access_token'] );
$_SESSION['api_response'] = (x($_SESSION, 'api_response') ? $_SESSION['api_response'] : '');
}
function get() {
$o .= replace_macros(get_markup_template('oauth2testvehicle.tpl'), array(
'$baseurl' => z_root(),
'$api_response' => $_SESSION['api_response'],
/*
endpoints => array(
array(
'path_to_endpoint',
array(
array('field_name_1', 'value'),
array('field_name_2', 'value'),
...
),
'submit_button_name',
'Description of API action'
)
)
*/
'$endpoints' => array(
array(
'authorize',
array(
array('response_type', 'code'),
array('client_id', (x($_REQUEST, 'client_id') ? $_REQUEST['client_id'] : 'oauth2_test_app')),
array('redirect_uri', $_SESSION['redirect_uri']),
array('state', 'xyz'),
// OpenID Connect Dynamic Client Registration 1.0 Client Metadata
// http://openid.net/specs/openid-connect-registration-1_0.html
array('client_name', 'OAuth2 Test App'),
array('logo_uri', urlencode(z_root() . '/images/icons/plugin.png')),
array('client_uri', urlencode('https://client.example.com/website')),
array('application_type', 'web'), // would be 'native' for mobile app
),
'oauth_authorize',
'Authorize a test client app',
'GET',
(($_REQUEST['code'] && $_REQUEST['state']) ? true : false),
),
array(
'oauth2testvehicle',
array(
array('action', 'request_token'),
array('grant_type', 'authorization_code'),
array('code', $_SESSION['authorization_code']),
array('redirect_uri', $_SESSION['redirect_uri']),
array('client_id', ($_SESSION['client_id'] ? $_SESSION['client_id'] : 'oauth2_test_app')),
array('client_secret', $_SESSION['client_secret']),
),
'oauth_token_request',
'Request a token',
'POST',
($_SESSION['success'] === 'request_token'),
),
array(
'oauth2testvehicle',
array(
array('action', 'api_files'),
array('access_token', $_SESSION['access_token']),
),
'oauth_api_files',
'API: Get channel files',
'POST',
($_SESSION['success'] === 'api_files'),
)
)
));
$_SESSION['success'] = '';
return $o;
}
function post() {
switch ($_POST['action']) {
case 'api_files':
$access_token = $_SESSION['access_token'];
$url = z_root() . '/api/z/1.0/files/';
$headers = [];
$headers[] = 'Authorization: Bearer ' . $access_token;
$post = z_fetch_url($url, false, 0, array(
'custom' => 'GET',
'headers' => $headers,
));
logger(json_encode($post, JSON_PRETTY_PRINT), LOGGER_DEBUG);
$response = json_decode($post['body'], true);
$_SESSION['api_response'] = json_encode($response, JSON_PRETTY_PRINT);
break;
case 'request_token':
$grant_type = (x($_POST, 'grant_type') ? $_POST['grant_type'] : '');
$redirect_uri = (x($_POST, 'redirect_uri') ? $_POST['redirect_uri'] : '');
$client_id = (x($_POST, 'client_id') ? $_POST['client_id'] : '');
$code = (x($_POST, 'code') ? $_POST['code'] : '');
$client_secret = (x($_POST, 'client_secret') ? $_POST['client_secret'] : '');
$url = z_root() . '/token/';
$params = http_build_query(array(
'grant_type' => $grant_type,
'redirect_uri' => urlencode($redirect_uri),
'client_id' => $client_id,
'code' => $code,
));
$post = z_post_url($url, $params, 0, array(
'http_auth' => $client_id . ':' . $client_secret,
));
logger(json_encode($post, JSON_PRETTY_PRINT), LOGGER_DEBUG);
$response = json_decode($post['body'], true);
logger(json_encode($response, JSON_PRETTY_PRINT), LOGGER_DEBUG);
if($response['access_token']) {
info('Access token received: ' . $response['access_token'] . EOL);
$_SESSION['success'] = 'request_token';
$_SESSION['access_token'] = $response['access_token'];
}
break;
default:
break;
}
}
}

View File

@@ -0,0 +1,69 @@
<?php
namespace Zotlabs\Module;
require_once('include/contact_widgets.php');
require_once('include/items.php');
require_once("include/bbcode.php");
require_once('include/security.php');
require_once('include/conversation.php');
require_once('include/acl_selectors.php');
require_once('include/permissions.php');
/**
* @brief Channel Controller for broken OStatus implementations
*
*/
class Ochannel extends \Zotlabs\Web\Controller {
function init() {
$which = null;
if(argc() > 1)
$which = argv(1);
if(! $which) {
if(local_channel()) {
$channel = \App::get_channel();
if($channel && $channel['channel_address'])
$which = $channel['channel_address'];
}
}
if(! $which) {
notice( t('You must be logged in to see this page.') . EOL );
return;
}
$profile = 0;
$channel = \App::get_channel();
if((local_channel()) && (argc() > 2) && (argv(2) === 'view')) {
$which = $channel['channel_address'];
$profile = argv(1);
}
head_add_link( [
'rel' => 'alternate',
'type' => 'application/atom+xml',
'href' => z_root() . '/ofeed/' . $which
]);
// Run profile_load() here to make sure the theme is set before
// we start loading content
profile_load($which,$profile);
}
function get($update = 0, $load = false) {
if(argc() < 2)
return;
if($load)
$_SESSION['loadtime'] = datetime_convert();
return '<script>window.location.href = "' . z_root() . '/' . str_replace('ochannel/','channel/',\App::$query_string) . '";</script>';
}
}

View File

@@ -72,7 +72,7 @@ class Oep extends \Zotlabs\Web\Controller {
$url = $args['url'];
$maxwidth = intval($args['maxwidth']);
$maxheight = intval($args['maxheight']);
logger('processing display');
if(preg_match('#//(.*?)/display/(.*?)(&|\?|$)#',$url,$matches)) {
$res = $matches[2];
}
@@ -125,6 +125,7 @@ class Oep extends \Zotlabs\Web\Controller {
"' profile='".$p[0]['author']['xchan_url'] .
"' avatar='".$p[0]['author']['xchan_photo_s'].
"' link='".$p[0]['plink'].
"' auth='".(($p[0]['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='".$p[0]['created'].
"' message_id='".$p[0]['mid']."']";
if($p[0]['title'])
@@ -209,6 +210,7 @@ class Oep extends \Zotlabs\Web\Controller {
"' profile='".$p[0]['author']['xchan_url'] .
"' avatar='".$p[0]['author']['xchan_photo_s'].
"' link='".$p[0]['plink'].
"' auth='".(($p[0]['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='".$p[0]['created'].
"' message_id='".$p[0]['mid']."']";
if($p[0]['title'])
@@ -292,6 +294,7 @@ class Oep extends \Zotlabs\Web\Controller {
"' profile='".$p[0]['author']['xchan_url'] .
"' avatar='".$p[0]['author']['xchan_photo_s'].
"' link='".$p[0]['plink'].
"' auth='".(($p[0]['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='".$p[0]['created'].
"' message_id='".$p[0]['mid']."']";
if($p[0]['title'])
@@ -366,6 +369,7 @@ class Oep extends \Zotlabs\Web\Controller {
"' profile='".$p[0]['author']['xchan_url'] .
"' avatar='".$p[0]['author']['xchan_photo_s'].
"' link='".$p[0]['plink'].
"' auth='".(($p[0]['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='".$p[0]['created'].
"' message_id='".$p[0]['mid']."']";
if($p[0]['title'])

View File

@@ -34,6 +34,15 @@ class Owa extends \Zotlabs\Web\Controller {
where hubloc_addr = '%s' ",
dbesc(str_replace('acct:','',$keyId))
);
if(! $r) {
$found = discover_by_webbie(str_replace('acct:','',$keyId));
if($found) {
$r = q("select * from hubloc left join xchan on hubloc_hash = xchan_hash
where hubloc_addr = '%s' ",
dbesc(str_replace('acct:','',$keyId))
);
}
}
if($r) {
foreach($r as $hubloc) {
$verified = \Zotlabs\Web\HTTPSig::verify('',$hubloc['xchan_pubkey']);

View File

@@ -127,69 +127,45 @@ class Photo extends \Zotlabs\Web\Controller {
}
}
$r = q("SELECT uid FROM photo WHERE resource_id = '%s' AND imgscale = %d LIMIT 1",
$r = q("SELECT uid, photo_usage FROM photo WHERE resource_id = '%s' AND imgscale = %d LIMIT 1",
dbesc($photo),
intval($resolution)
);
if($r) {
$allowed = (-1);
if(intval($r[0]['photo_usage'])) {
$allowed = 1;
if(intval($r[0]['photo_usage']) === PHOTO_COVER)
if($resolution < PHOTO_RES_COVER_1200)
$allowed = (-1);
if(intval($r[0]['photo_usage']) === PHOTO_PROFILE)
if(! in_array($resolution,[4,5,6]))
$allowed = (-1);
}
if($allowed === (-1))
$allowed = attach_can_view($r[0]['uid'],$observer_xchan,$photo);
$allowed = (($r[0]['uid']) ? perm_is_allowed($r[0]['uid'],$observer_xchan,'view_storage') : true);
$sql_extra = permissions_sql($r[0]['uid']);
if(! $sql_extra)
$sql_extra = ' and true ';
// Only check permissions on normal photos. Those photos we don't check includes
// profile photos, xchan photos (which are also profile photos), 'thing' photos,
// and cover photos
$sql_extra = " and (( photo_usage = 0 $sql_extra ) or photo_usage != 0 )";
$channel = channelx_by_n($r[0]['uid']);
// Now we'll see if we can access the photo
$r = q("SELECT * FROM photo WHERE resource_id = '%s' AND imgscale = %d $sql_extra LIMIT 1",
$e = q("SELECT * FROM photo WHERE resource_id = '%s' AND imgscale = %d $sql_extra LIMIT 1",
dbesc($photo),
intval($resolution)
);
// viewing cover photos is allowed unless a plugin chooses to block it.
$exists = (($e) ? true : false);
if($r && intval($r[0]['photo_usage']) === PHOTO_COVER && $resolution >= PHOTO_RES_COVER_1200)
$allowed = 1;
$d = [ 'imgscale' => $resolution, 'resource_id' => $photo, 'photo' => $r, 'allowed' => $allowed ];
call_hooks('get_photo',$d);
$resolution = $d['imgscale'];
$photo = $d['resource_id'];
$r = $d['photo'];
$allowed = $d['allowed'];
if($r && $allowed) {
$data = dbunescbin($r[0]['content']);
$mimetype = $r[0]['mimetype'];
if(intval($r[0]['os_storage'])) {
if($exists && $allowed) {
$data = dbunescbin($e[0]['content']);
$mimetype = $e[0]['mimetype'];
if(intval($e[0]['os_storage'])) {
$streaming = $data;
}
}
else {
// Does the picture exist? It may be a remote person with no credentials,
// but who should otherwise be able to view it. Show a default image to let
// them know permissions was denied. It may be possible to view the image
// through an authenticated profile visit.
// There won't be many completely unauthorised people seeing this because
// they won't have the photo link, so there's a reasonable chance that the person
// might be able to obtain permission to view it.
$r = q("SELECT * FROM photo WHERE resource_id = '%s' AND imgscale = %d LIMIT 1",
dbesc($photo),
intval($resolution)
);
if($r) {
if(! $allowed) {
logger('mod_photo: forbidden. ' . \App::$query_string);
$observer = \App::get_observer();
logger('mod_photo: observer = ' . (($observer) ? $observer['xchan_addr'] : '(not authenticated)'));
@@ -201,9 +177,6 @@ class Photo extends \Zotlabs\Web\Controller {
}
}
if(! isset($data)) {
if(isset($resolution)) {
switch($resolution) {
@@ -295,7 +268,6 @@ class Photo extends \Zotlabs\Web\Controller {
}
killme();
// NOTREACHED
}
}

View File

@@ -695,8 +695,8 @@ class Photos extends \Zotlabs\Web\Controller {
'$newalbum_label' => t('Enter an album name'),
'$newalbum_placeholder' => t('or select an existing album (doubleclick)'),
'$visible' => array('visible', t('Create a status post for this upload'), 0,'', array(t('No'), t('Yes')), 'onclick="showHideBodyTextarea();"'),
'$caption' => array('description', t('Caption (optional):')),
'$body' => array('body', t('Description (optional):'),'', 'Description will only appear in the status post'),
'$caption' => array('description', t('Title (optional)')),
'$body' => array('body', t('Description (optional)'),'', 'Description will only appear in the status post'),
'$albums' => $albums['albums'],
'$selname' => $selname,
'$permissions' => t('Permissions'),
@@ -833,7 +833,7 @@ class Photos extends \Zotlabs\Web\Controller {
killme();
}
else {
$o .= "<script> var page_query = '" . $_GET['q'] . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$o .= "<script> var page_query = '" . escape_tags($_GET['q']) . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$tpl = get_markup_template('photo_album.tpl');
$o .= replace_macros($tpl, array(
'$photos' => $photos,
@@ -841,7 +841,7 @@ class Photos extends \Zotlabs\Web\Controller {
'$album_id' => $datum,
'$album_edit' => array(t('Edit Album'), $album_edit),
'$can_post' => $can_post,
'$upload' => array(t('Upload'), z_root() . '/photos/' . \App::$data['channel']['channel_address'] . '/upload/' . $datum),
'$upload' => array(t('Add Photos'), z_root() . '/photos/' . \App::$data['channel']['channel_address'] . '/upload/' . $datum),
'$order' => $order,
'$upload_form' => $upload_form,
'$usage' => $usage_message
@@ -1065,7 +1065,7 @@ class Photos extends \Zotlabs\Web\Controller {
'newalbum_placeholder' => t('or select an existing one (doubleclick)'),
'nickname' => \App::$data['channel']['channel_address'],
'resource_id' => $ph[0]['resource_id'],
'capt_label' => t('Caption'),
'capt_label' => t('Title (optional)'),
'caption' => $caption_e,
'tag_label' => t('Add a Tag'),
'permissions' => t('Permissions'),
@@ -1148,10 +1148,10 @@ class Photos extends \Zotlabs\Web\Controller {
builtin_activity_puller($item, $conv_responses);
}
$like_count = ((x($alike,$link_item['mid'])) ? $alike[$link_item['mid']] : '');
$like_list = ((x($alike,$link_item['mid'])) ? $alike[$link_item['mid'] . '-l'] : '');
if (count($like_list) > MAX_LIKERS) {
if(is_array($like_list) && (count($like_list) > MAX_LIKERS)) {
$like_list_part = array_slice($like_list, 0, MAX_LIKERS);
array_push($like_list_part, '<a href="#" data-toggle="modal" data-target="#likeModal-' . $this->get_id() . '"><b>' . t('View all') . '</b></a>');
} else {
@@ -1163,7 +1163,7 @@ class Photos extends \Zotlabs\Web\Controller {
$dislike_count = ((x($dlike,$link_item['mid'])) ? $dlike[$link_item['mid']] : '');
$dislike_list = ((x($dlike,$link_item['mid'])) ? $dlike[$link_item['mid'] . '-l'] : '');
$dislike_button_label = tt('Dislike','Dislikes',$dislike_count,'noun');
if (count($dislike_list) > MAX_LIKERS) {
if (is_array($dislike_list) && (count($dislike_list) > MAX_LIKERS)) {
$dislike_list_part = array_slice($dislike_list, 0, MAX_LIKERS);
array_push($dislike_list_part, '<a href="#" data-toggle="modal" data-target="#dislikeModal-' . $this->get_id() . '"><b>' . t('View all') . '</b></a>');
} else {
@@ -1372,13 +1372,13 @@ class Photos extends \Zotlabs\Web\Controller {
killme();
}
else {
$o .= "<script> var page_query = '" . $_GET['q'] . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$o .= "<script> var page_query = '" . escape_tags($_GET['q']) . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$tpl = get_markup_template('photos_recent.tpl');
$o .= replace_macros($tpl, array(
'$title' => t('Recent Photos'),
'$album_id' => bin2hex(t('Recent Photos')),
'$can_post' => $can_post,
'$upload' => array(t('Upload'), z_root().'/photos/'.\App::$data['channel']['channel_address'].'/upload'),
'$upload' => array(t('Add Photos'), z_root().'/photos/'.\App::$data['channel']['channel_address'].'/upload'),
'$photos' => $photos,
'$upload_form' => $upload_form,
'$usage' => $usage_message

View File

@@ -140,7 +140,13 @@ class Ping extends \Zotlabs\Web\Controller {
db_utcnow(), db_quoteinterval('3 MINUTE')
);
$discover_tab_on = ((get_config('system','disable_discover_tab') || get_config('system','disable_discover_tab') === false) ? false : true);
$sql_extra = '';
if(! ($vnotify & VNOTIFY_LIKE))
$sql_extra = " AND verb NOT IN ('" . dbesc(ACTIVITY_LIKE) . "', '" . dbesc(ACTIVITY_DISLIKE) . "') ";
$discover_tab_on = can_view_public_stream();
$notify_pubs = ((local_channel()) ? ($vnotify & VNOTIFY_PUBS) && $discover_tab_on : $discover_tab_on);
if($notify_pubs) {
@@ -151,7 +157,8 @@ class Ping extends \Zotlabs\Web\Controller {
AND item_unseen = 1
AND author_xchan != '%s'
AND created > '" . datetime_convert('UTC','UTC',$_SESSION['static_loadtime']) . "'
$item_normal",
$item_normal
$sql_extra",
intval($sys['channel_id']),
dbesc(get_observer_hash())
);
@@ -160,6 +167,8 @@ class Ping extends \Zotlabs\Web\Controller {
$result['pubs'] = intval($pubs[0]['total']);
}
if((argc() > 1) && (argv(1) === 'pubs') && ($notify_pubs)) {
$sys = get_sys_channel();
$result = array();
@@ -170,6 +179,7 @@ class Ping extends \Zotlabs\Web\Controller {
AND author_xchan != '%s'
AND created > '" . datetime_convert('UTC','UTC',$_SESSION['static_loadtime']) . "'
$item_normal
$sql_extra
ORDER BY created DESC
LIMIT 300",
intval($sys['channel_id']),
@@ -275,10 +285,10 @@ class Ping extends \Zotlabs\Web\Controller {
intval(local_channel())
);
$b64mid = ((strpos($r[0]['thr_parent'], 'b64.' === 0)) ? $r[0]['thr_parent'] : 'b64.' . base64url_encode($r[0]['thr_parent']));
$b64mid = ((strpos($r[0]['thr_parent'], 'b64.') === 0) ? $r[0]['thr_parent'] : 'b64.' . base64url_encode($r[0]['thr_parent']));
}
else {
$b64mid = ((strpos($mid, 'b64.' === 0)) ? $mid : 'b64.' . base64url_encode($mid));
$b64mid = ((strpos($mid, 'b64.') === 0) ? $mid : 'b64.' . base64url_encode($mid));
}
$notifs[] = array(
@@ -334,6 +344,7 @@ class Ping extends \Zotlabs\Web\Controller {
AND item_unseen = 1
AND author_xchan != '%s'
$item_normal
$sql_extra
ORDER BY created DESC
LIMIT 300",
intval(local_channel()),
@@ -508,6 +519,7 @@ class Ping extends \Zotlabs\Web\Controller {
$r = q("SELECT id, item_wall FROM item
WHERE uid = %d and item_unseen = 1
$item_normal
$sql_extra
AND author_xchan != '%s'",
intval(local_channel()),
dbesc($ob_hash)

View File

@@ -451,6 +451,7 @@ class Profile_photo extends \Zotlabs\Web\Controller {
$o .= replace_macros($tpl,array(
'$user' => \App::$channel['channel_address'],
'$info' => ((count($profiles) > 1) ? t('Your default profile photo is visible to anybody on the internet. Profile photos for alternate profiles will inherit the permissions of the profile') : t('Your profile photo is visible to anybody on the internet and may be distributed to other websites.')),
'$importfile' => (($importing) ? \App::$data['importfile'] : ''),
'$lbl_upfile' => t('Upload File:'),
'$lbl_profiles' => t('Select a profile:'),

View File

@@ -655,7 +655,7 @@ class Profiles extends \Zotlabs\Web\Controller {
intval($id),
intval(local_channel())
);
if(! count($r)) {
if(! $r) {
notice( t('Profile not found.') . EOL);
return;
}
@@ -712,13 +712,10 @@ class Profiles extends \Zotlabs\Web\Controller {
$tpl = get_markup_template("profile_edit.tpl");
$o .= replace_macros($tpl,array(
'$multi_profiles' => ((feature_enabled(local_channel(),'multi_profiles')) ? true : false),
'$form_security_token' => get_form_security_token("profile_edit"),
'$profile_clone_link' => ((feature_enabled(local_channel(),'multi_profiles')) ? 'profiles/clone/' . $r[0]['id'] . '?t='
. get_form_security_token("profile_clone") : ''),
'$profile_drop_link' => 'profiles/drop/' . $r[0]['id'] . '?t='
. get_form_security_token("profile_drop"),
'$profile_clone_link' => 'profiles/clone/' . $r[0]['id'] . '?t=' . get_form_security_token("profile_clone"),
'$profile_drop_link' => 'profiles/drop/' . $r[0]['id'] . '?t=' . get_form_security_token("profile_drop"),
'$fields' => $fields,
'$vcard' => $vcard,
'$guid' => $r[0]['profile_guid'],
@@ -735,7 +732,7 @@ class Profiles extends \Zotlabs\Web\Controller {
'$addthing' => t('Add profile things'),
'$personal' => t('Personal'),
'$location' => t('Location'),
'$relation' => t('Relation'),
'$relation' => t('Relationship'),
'$miscellaneous'=> t('Miscellaneous'),
'$exportable' => feature_enabled(local_channel(),'profile_export'),
'$lbl_import' => t('Import profile from file'),
@@ -786,22 +783,22 @@ class Profiles extends \Zotlabs\Web\Controller {
'$channels' => array('channels', t('My other channels'), $r[0]['channels']),
'$extra_fields' => $extra_fields,
'$comms' => t('Communications'),
'$tel_label' => t('Phone'),
'$email_label' => t('Email'),
'$impp_label' => t('Instant messenger'),
'$url_label' => t('Website'),
'$adr_label' => t('Address'),
'$note_label' => t('Note'),
'$mobile' => t('Mobile'),
'$home' => t('Home'),
'$work' => t('Work'),
'$other' => t('Other'),
'$add_card' => t('Add Contact'),
'$add_field' => t('Add Field'),
'$create' => t('Create'),
'$update' => t('Update'),
'$delete' => t('Delete'),
'$cancel' => t('Cancel'),
'$tel_label' => t('Phone'),
'$email_label' => t('Email'),
'$impp_label' => t('Instant messenger'),
'$url_label' => t('Website'),
'$adr_label' => t('Address'),
'$note_label' => t('Note'),
'$mobile' => t('Mobile'),
'$home' => t('Home'),
'$work' => t('Work'),
'$other' => t('Other'),
'$add_card' => t('Add Contact'),
'$add_field' => t('Add Field'),
'$create' => t('Create'),
'$update' => t('Update'),
'$delete' => t('Delete'),
'$cancel' => t('Cancel'),
));
$arr = array('profile' => $r[0], 'entry' => $o);

View File

@@ -34,6 +34,8 @@ class Pubstream extends \Zotlabs\Web\Controller {
}
$mid = ((x($_REQUEST,'mid')) ? $_REQUEST['mid'] : '');
$hashtags = ((x($_REQUEST,'tag')) ? $_REQUEST['tag'] : '');
if(strpos($mid,'b64.') === 0)
$decoded = @base64url_decode(substr($mid,4));
@@ -116,8 +118,8 @@ class Pubstream extends \Zotlabs\Web\Controller {
'$uid' => ((local_channel()) ? local_channel() : '0'),
'$gid' => '0',
'$cid' => '0',
'$cmin' => '0',
'$cmax' => '99',
'$cmin' => '(-1)',
'$cmax' => '(-1)',
'$star' => '0',
'$liked' => '0',
'$conv' => '0',
@@ -133,7 +135,7 @@ class Pubstream extends \Zotlabs\Web\Controller {
'$order' => 'comment',
'$file' => '',
'$cats' => '',
'$tags' => '',
'$tags' => $hashtags,
'$dend' => '',
'$mid' => $mid,
'$verb' => '',
@@ -170,6 +172,10 @@ class Pubstream extends \Zotlabs\Web\Controller {
$page_mode = 'client';
if(x($hashtags)) {
$sql_extra .= protect_sprintf(term_query('item', $hashtags, TERM_HASHTAG, TERM_COMMUNITYTAG));
}
$net_query = (($net) ? " left join xchan on xchan_hash = author_xchan " : '');
$net_query2 = (($net) ? " and xchan_network = '" . protect_sprintf(dbesc($net)) . "' " : '');
@@ -224,7 +230,7 @@ class Pubstream extends \Zotlabs\Web\Controller {
);
}
else {
$r = q("SELECT distinct parent AS item_id, $ordering FROM item
$r = q("SELECT parent AS item_id FROM item
left join abook on item.author_xchan = abook.abook_xchan
$net_query
WHERE true $uids $item_normal_update
@@ -273,7 +279,7 @@ class Pubstream extends \Zotlabs\Web\Controller {
$o .= '<div id="content-complete"></div>';
if(($items) && (! $update))
$o .= alt_pager($a,count($items));
$o .= alt_pager(count($items));
return $o;

View File

@@ -49,6 +49,7 @@ class React extends \Zotlabs\Web\Controller {
$n['aid'] = $channel['channel_account_id'];
$n['uid'] = $channel['channel_id'];
$n['item_origin'] = true;
$n['item_type'] = $i[0]['item_type'];
$n['parent'] = $postid;
$n['parent_mid'] = $i[0]['mid'];
$n['mid'] = item_message_id();

View File

@@ -35,6 +35,8 @@ class Regmod extends \Zotlabs\Web\Controller {
if($cmd === 'allow') {
if (! account_allow($hash)) killme();
}
goaway('/admin/accounts');
}
}

View File

@@ -45,7 +45,9 @@ class Rpost extends \Zotlabs\Web\Controller {
$url = get_rpost_path(\App::get_observer());
// make sure we're not looping to our own hub
if(($url) && (! stristr($url, \App::get_hostname()))) {
foreach($_REQUEST as $key => $arg) {
foreach($_GET as $key => $arg) {
if($key === 'q')
continue;
$url .= '&' . $key . '=' . $arg;
}
goaway($url);
@@ -111,43 +113,7 @@ class Rpost extends \Zotlabs\Web\Controller {
}
if($_REQUEST['post_id']) {
$r = q("SELECT * from item WHERE id = %d LIMIT 1",
intval($_REQUEST['post_id'])
);
if(($r) && (! intval($r[0]['item_private']))) {
$sql_extra = item_permissions_sql($r[0]['uid']);
$r = q("select * from item where id = %d $sql_extra",
intval($_REQUEST['post_id'])
);
if($r && $r[0]['mimetype'] === 'text/bbcode') {
xchan_query($r);
$is_photo = (($r[0]['obj_type'] === ACTIVITY_OBJ_PHOTO) ? true : false);
if($is_photo) {
$object = json_decode($r[0]['obj'],true);
$photo_bb = $object['body'];
}
if (strpos($r[0]['body'], "[/share]") !== false) {
$pos = strpos($r[0]['body'], "[share");
$i = substr($r[0]['body'], $pos);
} else {
$i = "[share author='".urlencode($r[0]['author']['xchan_name']).
"' profile='".$r[0]['author']['xchan_url'] .
"' avatar='".$r[0]['author']['xchan_photo_s'].
"' link='".$r[0]['plink'].
"' posted='".$r[0]['created'].
"' message_id='".$r[0]['mid']."']";
if($r[0]['title'])
$i .= '[b]'.$r[0]['title'].'[/b]'."\r\n";
$i .= (($is_photo) ? $photo_bb . "\r\n" . $r[0]['body'] : $r[0]['body']);
$i .= "[/share]";
}
}
}
$_REQUEST['body'] = $_REQUEST['body'] . $i;
$_REQUEST['body'] .= '[share=' . intval($_REQUEST['post_id']) . '][/share]';
}
$x = array(

View File

@@ -66,6 +66,10 @@ class Search extends \Zotlabs\Web\Controller {
$search = substr($search,1);
goaway(z_root() . '/directory' . '?f=1&navsearch=1&search=' . $search);
}
if(strpos($search,'!') === 0) {
$search = substr($search,1);
goaway(z_root() . '/directory' . '?f=1&navsearch=1&search=' . $search);
}
if(strpos($search,'?') === 0) {
$search = substr($search,1);
goaway(z_root() . '/help' . '?f=1&navsearch=1&search=' . $search);
@@ -117,8 +121,8 @@ class Search extends \Zotlabs\Web\Controller {
'$uid' => ((\App::$profile['profile_uid']) ? \App::$profile['profile_uid'] : '0'),
'$gid' => '0',
'$cid' => '0',
'$cmin' => '0',
'$cmax' => '0',
'$cmin' => '(-1)',
'$cmax' => '(-1)',
'$star' => '0',
'$liked' => '0',
'$conv' => '0',
@@ -171,7 +175,7 @@ class Search extends \Zotlabs\Web\Controller {
OR ( item.uid = %d )) OR item.owner_xchan = '%s' )
$item_normal
$sql_extra
group by mid order by created desc $pager_sql ",
group by mid, created order by created desc $pager_sql ",
intval(local_channel()),
dbesc($sys['xchan_hash'])
);
@@ -184,7 +188,7 @@ class Search extends \Zotlabs\Web\Controller {
$pub_sql ) OR owner_xchan = '%s')
$item_normal
$sql_extra
group by mid order by created desc $pager_sql",
group by mid, created order by created desc $pager_sql",
dbesc($sys['xchan_hash'])
);
}

View File

@@ -202,12 +202,14 @@ class Channel {
$vnotify += intval($_POST['vnotify9']);
if(x($_POST,'vnotify10'))
$vnotify += intval($_POST['vnotify10']);
if(x($_POST,'vnotify11'))
if(x($_POST,'vnotify11') && is_site_admin())
$vnotify += intval($_POST['vnotify11']);
if(x($_POST,'vnotify12'))
$vnotify += intval($_POST['vnotify12']);
if(x($_POST,'vnotify13'))
$vnotify += intval($_POST['vnotify13']);
if(x($_POST,'vnotify14'))
$vnotify += intval($_POST['vnotify14']);
$always_show_in_notices = x($_POST,'always_show_in_notices') ? 1 : 0;
@@ -412,12 +414,16 @@ class Channel {
));
$subdir = ((strlen(\App::get_path())) ? '<br />' . t('or') . ' ' . z_root() . '/channel/' . $nickname : '');
$webbie = $nickname . '@' . \App::get_hostname();
$intl_nickname = unpunify($nickname) . '@' . unpunify(\App::get_hostname());
$tpl_addr = get_markup_template("settings_nick_set.tpl");
$prof_addr = replace_macros($tpl_addr,array(
'$desc' => t('Your channel address is'),
'$nickname' => $nickname,
'$nickname' => (($intl_nickname === $webbie) ? $webbie : $intl_nickname . '&nbsp;(' . $webbie . ')'),
'$subdir' => $subdir,
'$davdesc' => t('Your files/photos are accessible via WebDAV at'),
'$davpath' => ((get_account_techlevel() > 3) ? z_root() . '/dav/' . $nickname : ''),
@@ -480,7 +486,8 @@ class Channel {
$plugin = [ 'basic' => '', 'security' => '', 'notify' => '', 'misc' => '' ];
call_hooks('channel_settings',$plugin);
$disable_discover_tab = get_config('system','disable_discover_tab') || get_config('system','disable_discover_tab') === false;
$disable_discover_tab = intval(get_config('system','disable_discover_tab',1)) == 1;
$site_firehose = intval(get_config('system','site_firehose',0)) == 1;
$o .= replace_macros($stpl,array(
'$ptitle' => t('Channel Settings'),
@@ -529,7 +536,7 @@ class Channel {
'$deny_gid' => acl2json($perm_defaults['deny_gid']),
'$suggestme' => $suggestme,
'$group_select' => $group_select,
'$role' => array('permissions_role' , t('Channel permissions category:'), $permissions_role, '', $perm_roles),
'$role' => array('permissions_role' , t('Channel role and privacy'), $permissions_role, '', $perm_roles),
'$defpermcat' => [ 'defpermcat', t('Default Permissions Group'), $default_permcat, '', $permcats ],
'$permcat_enable' => feature_enabled(local_channel(),'permcats'),
'$profile_in_dir' => $profile_in_dir,
@@ -569,11 +576,12 @@ class Channel {
'$vnotify8' => array('vnotify8', t('System info messages'), ($vnotify & VNOTIFY_INFO), VNOTIFY_INFO, t('Recommended'), $yes_no),
'$vnotify9' => array('vnotify9', t('System critical alerts'), ($vnotify & VNOTIFY_ALERT), VNOTIFY_ALERT, t('Recommended'), $yes_no),
'$vnotify10' => array('vnotify10', t('New connections'), ($vnotify & VNOTIFY_INTRO), VNOTIFY_INTRO, t('Recommended'), $yes_no),
'$vnotify11' => array('vnotify11', t('System Registrations'), ($vnotify & VNOTIFY_REGISTER), VNOTIFY_REGISTER, '', $yes_no),
'$vnotify11' => ((is_site_admin()) ? array('vnotify11', t('System Registrations'), ($vnotify & VNOTIFY_REGISTER), VNOTIFY_REGISTER, '', $yes_no) : array()),
'$vnotify12' => array('vnotify12', t('Unseen shared files'), ($vnotify & VNOTIFY_FILES), VNOTIFY_FILES, '', $yes_no),
'$vnotify13' => (($disable_discover_tab) ? array() : array('vnotify13', t('Unseen public activity'), ($vnotify & VNOTIFY_PUBS), VNOTIFY_PUBS, '', $yes_no)),
'$vnotify13' => (($disable_discover_tab && !$site_firehose) ? array() : array('vnotify13', t('Unseen public activity'), ($vnotify & VNOTIFY_PUBS), VNOTIFY_PUBS, '', $yes_no)),
'$vnotify14' => array('vnotify14', t('Unseen likes and dislikes'), ($vnotify & VNOTIFY_LIKE), VNOTIFY_LIKE, '', $yes_no),
'$mailhost' => [ 'mailhost', t('Email notification hub (hostname)'), get_pconfig(local_channel(),'system','email_notify_host',\App::get_hostname()), sprintf( t('If your channel is mirrored to multiple hubs, set this to your preferred location. This will prevent duplicate email notifications. Example: %s'),\App::get_hostname()) ],
'$always_show_in_notices' => array('always_show_in_notices', t('Also show new wall posts, private messages and connections under Notices'), $always_show_in_notices, 1, '', $yes_no),
'$always_show_in_notices' => array('always_show_in_notices', t('Show new wall posts, private messages and connections under Notices'), $always_show_in_notices, 1, '', $yes_no),
'$evdays' => array('evdays', t('Notify me of events this many days in advance'), $evdays, t('Must be greater than 0')),
'$basic_addon' => $plugin['basic'],

View File

@@ -57,7 +57,10 @@ class Featured {
}
call_hooks('feature_settings', $settings_addons);
$this->sortpanels($settings_addons);
$tpl = get_markup_template("settings_addons.tpl");
$o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_featured"),
@@ -67,5 +70,15 @@ class Featured {
));
return $o;
}
}
function sortpanels(&$s) {
$a = explode('<div class="panel">',$s);
if($a) {
usort($a,'featured_sort');
$s = implode('<div class="panel">',$a);
}
}
}

View File

@@ -8,43 +8,75 @@ class Features {
function post() {
check_form_security_token_redirectOnErr('/settings/features', 'settings_features');
// Build list of features and check which are set
// We will not create any settings for features that are above our techlevel
$features = get_features(false);
$features = get_features();
$all_features = array();
foreach($features as $k => $v) {
foreach($v as $f)
$all_features[] = $f[0];
}
foreach($all_features as $k) {
if(x($_POST,"feature_$k"))
set_pconfig(local_channel(),'feature',$k, 1);
else
set_pconfig(local_channel(),'feature',$k, 0);
foreach($features as $fname => $fdata) {
foreach(array_slice($fdata,1) as $f) {
$k = $f[0];
if(array_key_exists("feature_$k",$_POST))
set_pconfig(local_channel(),'feature',$k, (string) $_POST["feature_$k"]);
else
set_pconfig(local_channel(),'feature', $k, '');
}
}
build_sync_packet();
return;
}
function get() {
$arr = array();
$features = get_features();
$arr = [];
$harr = [];
if(intval($_REQUEST['techlevel']))
$level = intval($_REQUEST['techlevel']);
else {
$level = get_account_techlevel();
}
if(! intval($level)) {
notice( t('Permission denied.') . EOL);
return;
}
$techlevels = \Zotlabs\Lib\Techlevels::levels();
// This page isn't accessible at techlevel 0
unset($techlevels[0]);
$def_techlevel = (($level > 0) ? $level : 1);
$techlock = get_config('system','techlevel_lock');
$all_features_raw = get_features(false);
foreach($all_features_raw as $fname => $fdata) {
foreach(array_slice($fdata,1) as $f) {
$harr[$f[0]] = ((intval(feature_enabled(local_channel(),$f[0]))) ? "1" : '');
}
}
$features = get_features(true,$level);
foreach($features as $fname => $fdata) {
$arr[$fname] = array();
$arr[$fname][0] = $fdata[0];
foreach(array_slice($fdata,1) as $f) {
$arr[$fname][1][] = array('feature_' .$f[0],$f[1],((intval(feature_enabled(local_channel(),$f[0]))) ? "1" : ''),$f[2],array(t('Off'),t('On')));
$arr[$fname][1][] = array('feature_' . $f[0],$f[1],((intval(feature_enabled(local_channel(),$f[0]))) ? "1" : ''),$f[2],array(t('Off'),t('On')));
unset($harr[$f[0]]);
}
}
$tpl = get_markup_template("settings_features.tpl");
$o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_features"),
'$title' => t('Additional Features'),
'$features' => $arr,
'$submit' => t('Submit'),
'$title' => t('Additional Features'),
'$techlevel' => [ 'techlevel', t('Your technical skill level'), $def_techlevel, t('Used to provide a member experience and additional features consistent with your comfort level'), $techlevels ],
'$techlock' => $techlock,
'$features' => $arr,
'$hiddens' => $harr,
'$baseurl' => z_root(),
'$submit' => t('Submit'),
));
return $o;

View File

@@ -23,11 +23,12 @@ class Oauth {
check_form_security_token_redirectOnErr('/settings/oauth', 'settings_oauth');
$name = ((x($_POST,'name')) ? $_POST['name'] : '');
$key = ((x($_POST,'key')) ? $_POST['key'] : '');
$secret = ((x($_POST,'secret')) ? $_POST['secret'] : '');
$redirect = ((x($_POST,'redirect')) ? $_POST['redirect'] : '');
$icon = ((x($_POST,'icon')) ? $_POST['icon'] : '');
$name = ((x($_POST,'name')) ? escape_tags($_POST['name']) : '');
$key = ((x($_POST,'key')) ? escape_tags($_POST['key']) : '');
$secret = ((x($_POST,'secret')) ? escape_tags($_POST['secret']) : '');
$redirect = ((x($_POST,'redirect')) ? escape_tags($_POST['redirect']) : '');
$icon = ((x($_POST,'icon')) ? escape_tags($_POST['icon']) : '');
$oauth2 = ((x($_POST,'oauth2')) ? intval($_POST['oauth2']) : 0);
$ok = true;
if($name == '') {
$ok = false;

View File

@@ -0,0 +1,161 @@
<?php
namespace Zotlabs\Module\Settings;
class Oauth2 {
function post() {
if(x($_POST,'remove')){
check_form_security_token_redirectOnErr('/settings/oauth2', 'settings_oauth2');
$key = $_POST['remove'];
q("DELETE FROM tokens WHERE id='%s' AND uid=%d",
dbesc($key),
intval(local_channel())
);
goaway(z_root()."/settings/oauth2/");
return;
}
if((argc() > 2) && (argv(2) === 'edit' || argv(2) === 'add') && x($_POST,'submit')) {
check_form_security_token_redirectOnErr('/settings/oauth2', 'settings_oauth2');
$name = ((x($_POST,'name')) ? escape_tags(trim($_POST['name'])) : '');
$secret = ((x($_POST,'secret')) ? escape_tags(trim($_POST['secret'])) : '');
$redirect = ((x($_POST,'redirect')) ? escape_tags(trim($_POST['redirect'])) : '');
$grant = ((x($_POST,'grant')) ? escape_tags(trim($_POST['grant'])) : '');
$scope = ((x($_POST,'scope')) ? escape_tags(trim($_POST['scope'])) : '');
$ok = true;
if($name == '' || $secret == '') {
$ok = false;
notice( t('Name and Secret are required') . EOL);
}
if($ok) {
if ($_POST['submit']==t("Update")){
$r = q("UPDATE oauth_clients SET
client_id = '%s',
client_secret = '%s',
redirect_uri = '%s',
grant_types = '%s',
scope = '%s',
user_id = %d
WHERE client_id='%s'",
dbesc($name),
dbesc($secret),
dbesc($redirect),
dbesc($grant),
dbesc($scope),
intval(local_channel()),
dbesc($name));
} else {
$r = q("INSERT INTO oauth_clients (client_id, client_secret, redirect_uri, grant_types, scope, user_id)
VALUES ('%s','%s','%s','%s','%s',%d)",
dbesc($name),
dbesc($secret),
dbesc($redirect),
dbesc($grant),
dbesc($scope),
intval(local_channel())
);
$r = q("INSERT INTO xperm (xp_client, xp_channel, xp_perm) VALUES ('%s', %d, '%s') ",
dbesc($name),
intval(local_channel()),
dbesc('all')
);
}
}
goaway(z_root()."/settings/oauth2/");
return;
}
}
function get() {
if((argc() > 2) && (argv(2) === 'add')) {
$tpl = get_markup_template("settings_oauth2_edit.tpl");
$o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_oauth2"),
'$title' => t('Add OAuth2 application'),
'$submit' => t('Submit'),
'$cancel' => t('Cancel'),
'$name' => array('name', t('Name'), '', t('Name of application')),
'$secret' => array('secret', t('Consumer Secret'), random_string(16), t('Automatically generated - change if desired. Max length 20')),
'$redirect' => array('redirect', t('Redirect'), '', t('Redirect URI - leave blank unless your application specifically requires this')),
'$grant' => array('grant', t('Grant Types'), '', t('leave blank unless your application sepcifically requires this')),
'$scope' => array('scope', t('Authorization scope'), '', t('leave blank unless your application sepcifically requires this')),
));
return $o;
}
if((argc() > 3) && (argv(2) === 'edit')) {
$r = q("SELECT * FROM oauth_clients WHERE client_id='%s' AND user_id= %d",
dbesc(argv(3)),
intval(local_channel())
);
if (! $r){
notice(t('OAuth2 Application not found.'));
return;
}
$app = $r[0];
$tpl = get_markup_template("settings_oauth2_edit.tpl");
$o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_oauth2"),
'$title' => t('Add application'),
'$submit' => t('Update'),
'$cancel' => t('Cancel'),
'$name' => array('name', t('Name'), $app['client_id'], t('Name of application')),
'$secret' => array('secret', t('Consumer Secret'), $app['client_secret'], t('Automatically generated - change if desired. Max length 20')),
'$redirect' => array('redirect', t('Redirect'), $app['redirect_uri'], t('Redirect URI - leave blank unless your application specifically requires this')),
'$grant' => array('grant', t('Grant Types'), $app['grant_types'], t('leave blank unless your application sepcifically requires this')),
'$scope' => array('scope', t('Authorization scope'), $app['scope'], t('leave blank unless your application sepcifically requires this')),
));
return $o;
}
if((argc() > 3) && (argv(2) === 'delete')) {
check_form_security_token_redirectOnErr('/settings/oauth2', 'settings_oauth2', 't');
$r = q("DELETE FROM oauth_clients WHERE client_id = '%s' AND user_id = %d",
dbesc(argv(3)),
intval(local_channel())
);
goaway(z_root()."/settings/oauth2/");
return;
}
$r = q("SELECT oauth_clients.*, oauth_access_tokens.access_token as oauth_token, (oauth_clients.user_id = %d) AS my
FROM oauth_clients
LEFT JOIN oauth_access_tokens ON oauth_clients.client_id=oauth_access_tokens.client_id
WHERE oauth_clients.user_id IN (%d,0)",
intval(local_channel()),
intval(local_channel())
);
$tpl = get_markup_template("settings_oauth2.tpl");
$o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_oauth2"),
'$baseurl' => z_root(),
'$title' => t('Connected OAuth2 Apps'),
'$add' => t('Add application'),
'$edit' => t('Edit'),
'$delete' => t('Delete'),
'$consumerkey' => t('Client key starts with'),
'$noname' => t('No name'),
'$remove' => t('Remove authorization'),
'$apps' => $r,
));
return $o;
}
}

View File

@@ -19,6 +19,11 @@ class Permcats {
$all_perms = \Zotlabs\Access\Permissions::Perms();
$name = escape_tags(trim($_POST['name']));
if(! $name) {
notice( t('Permission Name is required.') . EOL);
return;
}
$pcarr = [];

View File

@@ -563,16 +563,20 @@ class Setup extends \Zotlabs\Web\Controller {
$status = true;
$help = '';
if( (file_exists('.htconfig.php') && !is_writable('.htconfig.php')) ||
(!file_exists('.htconfig.php') && !is_writable('.')) ) {
$status = false;
$help = t('The web installer needs to be able to create a file called ".htconfig.php" in the top folder of your web server and it is unable to do so.') .EOL;
$help .= t('This is most often a permission setting, as the web server may not be able to write files in your folder - even if you can.').EOL;
$help .= t('At the end of this procedure, we will give you a text to save in a file named .htconfig.php in your Red top folder.').EOL;
$help .= t('You can alternatively skip this procedure and perform a manual installation. Please see the file "install/INSTALL.txt" for instructions.').EOL;
$fname = '.htconfig.php';
if((file_exists($fname) && is_writable($fname)) ||
(! (file_exists($fname) && is_writable('.')))) {
$this->check_add($checks, t('.htconfig.php is writable'), $status, true, $help);
return;
}
$this->check_add($checks, t('.htconfig.php is writable'), $status, false, $help);
$status = false;
$help = t('The web installer needs to be able to create a file called ".htconfig.php" in the top folder of your web server and it is unable to do so.') .EOL;
$help .= t('This is most often a permission setting, as the web server may not be able to write files in your folder - even if you can.').EOL;
$help .= t('Please see install/INSTALL.txt for additional information.');
$this->check_add($checks, t('.htconfig.php is writable'), $status, true, $help);
}
/**

View File

@@ -14,10 +14,15 @@ class Share extends \Zotlabs\Web\Controller {
if(! $post_id)
killme();
echo '[share=' . $post_id . '][/share]';
killme();
/**
* The remaining code is deprecated and handled in Zotlabs/Lib/Share.php at post
* submission time.
*/
if(! (local_channel() || remote_channel()))
killme();
@@ -60,12 +65,14 @@ class Share extends \Zotlabs\Web\Controller {
$pos = strpos($r[0]['body'], "[share");
$o = substr($r[0]['body'], $pos);
} else {
$o = "[share author='".urlencode($r[0]['author']['xchan_name']).
"' profile='".$r[0]['author']['xchan_url'] .
"' avatar='".$r[0]['author']['xchan_photo_s'].
"' link='".$r[0]['plink'].
"' posted='".$r[0]['created'].
"' message_id='".$r[0]['mid']."']";
$o = "[share author='" . urlencode($r[0]['author']['xchan_name']) .
"' profile='" . $r[0]['author']['xchan_url'] .
"' avatar='" . $r[0]['author']['xchan_photo_s'] .
"' link='" . $r[0]['plink'] .
"' auth='" . (($r[0]['author']['network'] === 'zot') ? 'true' : 'false') .
"' posted='" . $r[0]['created'] .
"' message_id='" . $r[0]['mid'] .
"']";
if($r[0]['title'])
$o .= '[b]'.$r[0]['title'].'[/b]'."\r\n";
$o .= (($is_photo) ? $photo_bb . "\r\n" . $r[0]['body'] : $r[0]['body']);

View File

@@ -80,6 +80,8 @@ class Tagger extends \Zotlabs\Web\Controller {
break;
}
$clean_term = trim($term,'"\' ');
$links = array(array('rel' => 'alternate','type' => 'text/html',
'href' => z_root() . '/display/' . gen_link_id($item['mid'])));
@@ -103,15 +105,15 @@ class Tagger extends \Zotlabs\Web\Controller {
),
));
$tagid = z_root() . '/search?tag=' . $term;
$tagid = z_root() . '/search?tag=' . $clean_term;
$objtype = ACTIVITY_OBJ_TAGTERM;
$obj = json_encode(array(
'type' => $objtype,
'id' => $tagid,
'link' => array(array('rel' => 'alternate','type' => 'text/html', 'href' => $tagid)),
'title' => $term,
'content' => $term
'title' => $clean_term,
'content' => $clean_term
));
$bodyverb = t('%1$s tagged %2$s\'s %3$s with %4$s');
@@ -119,7 +121,7 @@ class Tagger extends \Zotlabs\Web\Controller {
// saving here for reference
// also check out x22d5 and x2317 and x0d6b and x0db8 and x24d0 and xff20 !!!
$termlink = html_entity_decode('&#x22d5;') . '[zrl=' . z_root() . '/search?tag=' . urlencode($term) . ']'. $term . '[/zrl]';
$termlink = html_entity_decode('&#x22d5;') . '[zrl=' . z_root() . '/search?tag=' . urlencode($clean_term) . ']'. $clean_term . '[/zrl]';
$channel = \App::get_channel();
@@ -143,8 +145,7 @@ class Tagger extends \Zotlabs\Web\Controller {
$arr['obj_type'] = $objtype;
$arr['obj'] = $obj;
$arr['parent_mid'] = $item['mid'];
store_item_tag($item['uid'],$item['id'],TERM_OBJ_POST,TERM_COMMUNITYTAG,$term,$tagid);
store_item_tag($item['uid'],$item['id'],TERM_OBJ_POST,TERM_COMMUNITYTAG,$clean_term,$tagid);
$ret = post_activity_item($arr);
if($ret['success']) {

View File

@@ -29,7 +29,8 @@ class Token extends \Zotlabs\Web\Controller {
}
$s = new \Zotlabs\Identity\OAuth2Server(new OAuth2Storage(\DBA::$dba->db));
$s->handleTokenRequest(\OAuth2\Request::createFromGlobals())->send();
$request = \OAuth2\Request::createFromGlobals();
$s->handleTokenRequest($request)->send();
killme();
}

View File

@@ -22,8 +22,8 @@ class Uexport extends \Zotlabs\Web\Controller {
$month = intval(argv(2));
}
header('content-type: application/octet_stream');
header('content-disposition: attachment; filename="' . $channel['channel_address'] . (($year) ? '-' . $year : '') . (($month) ? '-' . $month : '') . '.json"' );
header('content-type: application/json');
header('content-disposition: attachment; filename="' . $channel['channel_address'] . (($year) ? '-' . $year : '') . (($month) ? '-' . $month : '') . (($_REQUEST['sections']) ? '-' . $_REQUEST['sections'] : '') . '.json"' );
if($year) {
echo json_encode(identity_export_year(local_channel(),$year,$month));

View File

@@ -107,7 +107,7 @@ class Viewconnections extends \Zotlabs\Web\Controller {
killme();
}
else {
$o .= "<script> var page_query = '" . $_GET['q'] . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$o .= "<script> var page_query = '" . escape_tags($_GET['q']) . "'; var extra_args = '" . extra_query_args() . "' ; </script>";
$tpl = get_markup_template("viewcontact_template.tpl");
$o .= replace_macros($tpl, array(
'$title' => t('View Connections'),

View File

@@ -17,33 +17,15 @@ class Webfinger extends \Zotlabs\Web\Controller {
$o .= '<br /><br />';
$old = false;
if(x($_GET,'addr')) {
$addr = trim($_GET['addr']);
// if(strpos($addr,'@') !== false) {
$res = webfinger_rfc7033($addr,true);
if(! $res) {
$res = old_webfinger($addr);
$old = true;
}
// }
// else {
// if(function_exists('lrdd'))
// $res = lrdd($addr);
// }
if($res && $old) {
foreach($res as $r) {
if($r['@attributes']['rel'] === 'http://microformats.org/profile/hcard') {
$hcard = unamp($r['@attributes']['href']);
require_once('library/HTML5/Parser.php');
$res['vcard'] = scrape_vcard($hcard);
break;
}
}
$res = webfinger_rfc7033($addr,true);
if(! $res) {
$res = old_webfinger($addr);
}
$o .= '<pre>';
$o .= str_replace("\n",'<br />',print_r($res,true));
$o .= '</pre>';

View File

@@ -26,7 +26,6 @@ class Well_known extends \Zotlabs\Web\Controller {
killme();
}
switch(argv(1)) {
case 'zot-info':
\App::$argc -= 1;
@@ -52,6 +51,10 @@ class Well_known extends \Zotlabs\Web\Controller {
$module->init();
break;
case 'dnt-policy.txt':
echo file_get_contents('doc/dnt-policy.txt');
killme();
default:
if(file_exists(\App::$cmd)) {
echo file_get_contents(\App::$cmd);

View File

@@ -284,6 +284,8 @@ class Wiki extends \Zotlabs\Web\Controller {
$wikiheaderPage = urldecode($pageUrlName);
$renamePage = (($wikiheaderPage === 'Home') ? '' : t('Rename page'));
$sharePage = t('Share');
$p = [];
if(! $ignore_language) {
@@ -354,6 +356,8 @@ class Wiki extends \Zotlabs\Web\Controller {
'$wikiheaderName' => $wikiheaderName,
'$wikiheaderPage' => $wikiheaderPage,
'$renamePage' => $renamePage,
'$sharePage' => $sharePage,
'$shareLink' => urlencode('#^[zrl=' . z_root() . '/wiki/' . argv(1) . '/' . $wikiUrlName . '/' . $pageUrlName . ']' . '[ ' . $owner['channel_name'] . ' ] ' . $wikiheaderName . ' - ' . $wikiheaderPage . '[/zrl]'),
'$showPageControls' => $showPageControls,
'$editOrSourceLabel' => (($showPageControls) ? t('Edit') : t('Source')),
'$tools_label' => 'Page Tools',

View File

@@ -274,7 +274,7 @@ class Browser extends DAV\Browser\Plugin {
'$actionspanel' => $output,
'$shared' => t('Shared'),
'$create' => t('Create'),
'$upload' => t('Upload'),
'$upload' => t('Add Files'),
'$is_owner' => $is_owner,
'$parentpath' => $parentpath,
'$cpath' => bin2hex(\App::$query_string),

View File

@@ -169,7 +169,7 @@ class Directory extends DAV\Node implements DAV\ICollection, DAV\IQuota, DAV\IMo
$x = attach_syspaths($this->auth->owner_id,$this->folder_hash);
$y = q("update attach set display_path = '%s where hash = '%s' and uid = %d",
$y = q("update attach set display_path = '%s' where hash = '%s' and uid = %d",
dbesc($x['path']),
dbesc($this->folder_hash),
intval($this->auth->owner_id)
@@ -389,8 +389,12 @@ class Directory extends DAV\Node implements DAV\ICollection, DAV\IQuota, DAV\IMo
);
if ($r) {
// When initiated from DAV, set the 'force' flag on attach_mkdir(). This will cause the operation to report success even if the
// folder already exists.
require_once('include/attach.php');
$result = attach_mkdir($r[0], $this->auth->observer, array('filename' => $name, 'folder' => $this->folder_hash));
$result = attach_mkdir($r[0], $this->auth->observer, array('filename' => $name, 'folder' => $this->folder_hash, 'force' => true));
if($result['success']) {
$sync = attach_export_data($r[0],$result['data']['hash']);
@@ -680,7 +684,7 @@ class Directory extends DAV\Node implements DAV\ICollection, DAV\IQuota, DAV\IMo
throw new DAV\Exception\Forbidden('Permission denied.');
}
else {
throw new DAV\Exception\NotFound('A component of the request file path could not be found.');
throw new DAV\Exception\NotFound('A component of the requested file path could not be found.');
}
}
@@ -691,7 +695,23 @@ class Directory extends DAV\Node implements DAV\ICollection, DAV\IQuota, DAV\IMo
}
$prefix = '';
$suffix = ' order by is_dir desc, filename asc ';
if(! array_key_exists('cloud_sort',$_SESSION))
$_SESSION['cloud_sort'] = 'name';
switch($_SESSION['cloud_sort']) {
case 'size':
$suffix = ' order by is_dir desc, filesize asc ';
break;
// The following provides inconsistent results for directories because we re-calculate the date for directories based on the most recent change
case 'date':
$suffix = ' order by is_dir desc, edited asc ';
break;
case 'name':
default:
$suffix = ' order by is_dir desc, filename asc ';
break;
}
$r = q("select $prefix id, uid, hash, filename, filetype, filesize, revision, folder, flags, is_dir, created, edited from attach where folder = '%s' and uid = %d $perms $suffix",
dbesc($folder),

View File

@@ -49,7 +49,7 @@ class File extends DAV\Node implements DAV\IFile {
$this->data = $data;
$this->auth = $auth;
logger(print_r($this->data, true), LOGGER_DATA);
// logger(print_r($this->data, true), LOGGER_DATA);
}
/**

View File

@@ -0,0 +1,10 @@
<?php
namespace Zotlabs\Storage;
class ZotOauth2Pdo extends \OAuth2\Storage\Pdo {
public function getConfig()
{
return $this->config;
}
}

26
Zotlabs/Update/_1208.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
namespace Zotlabs\Update;
class _1208 {
function run() {
if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
$r1 = q("ALTER TABLE poll ADD poll_author text NOT NULL");
$r2 = q("create index \"poll_author_idx\" on poll (\"poll_author\") ");
$r = ($r1 && $r2);
}
else {
$r = q("ALTER TABLE `poll` ADD `poll_author` VARCHAR(191) NOT NULL AFTER `poll_votes`,
ADD INDEX `poll_author` (`poll_author`)");
}
if($r)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
}

26
Zotlabs/Update/_1209.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
namespace Zotlabs\Update;
class _1209 {
function run() {
if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
$r1 = q("ALTER TABLE poll_elm ADD pelm_order numeric(6) NOT NULL DEFAULT '0' ");
$r2 = q("create index \"pelm_order_idx\" on poll_elm (\"pelm_order\")");
$r = ($r1 && $r2);
}
else {
$r = q("ALTER TABLE `poll_elm` ADD `pelm_order` int(11) NOT NULL DEFAULT 0,
ADD INDEX `pelm_order` (`pelm_order`)");
}
if($r)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
}

78
Zotlabs/Update/_1210.php Normal file
View File

@@ -0,0 +1,78 @@
<?php
namespace Zotlabs\Update;
class _1210 {
function run() {
$sql = "CREATE TABLE oauth_clients (
client_id VARCHAR(80) NOT NULL,
client_secret VARCHAR(80),
redirect_uri VARCHAR(2000),
grant_types VARCHAR(80),
scope VARCHAR(4000),
user_id VARCHAR(80),
PRIMARY KEY (client_id)
);
CREATE TABLE oauth_access_tokens (
access_token VARCHAR(40) NOT NULL,
client_id VARCHAR(80) NOT NULL,
user_id VARCHAR(255),
expires TIMESTAMP NOT NULL,
scope VARCHAR(4000),
PRIMARY KEY (access_token)
);
CREATE TABLE oauth_authorization_codes (
authorization_code VARCHAR(40) NOT NULL,
client_id VARCHAR(80) NOT NULL,
user_id VARCHAR(255),
redirect_uri VARCHAR(2000),
expires TIMESTAMP NOT NULL,
scope VARCHAR(4000),
id_token VARCHAR(1000),
PRIMARY KEY (authorization_code)
);
CREATE TABLE oauth_refresh_tokens (
refresh_token VARCHAR(40) NOT NULL,
client_id VARCHAR(80) NOT NULL,
user_id VARCHAR(255),
expires TIMESTAMP NOT NULL,
scope VARCHAR(4000),
PRIMARY KEY (refresh_token)
);
CREATE TABLE oauth_scopes (
scope VARCHAR(191) NOT NULL,
is_default SMALLINT,
PRIMARY KEY (scope)
);
CREATE TABLE oauth_jwt (
client_id VARCHAR(80) NOT NULL,
subject VARCHAR(80),
public_key VARCHAR(2000) NOT NULL
);
";
$arr = explode(';', $sql);
$errors = 0;
foreach($arr as $a) {
if(strlen(trim($a))) {
$r = dbq(trim($a));
if(! $r) {
$errors ++;
}
}
}
if(! $errors)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
}

26
Zotlabs/Update/_1211.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
namespace Zotlabs\Update;
class _1211 {
function run() {
if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
$r1 = q("ALTER TABLE channel ADD channel_active timestamp NOT NULL DEFAULT '0001-01-01 00:00:00' ");
$r2 = q("create index \"channel_active_idx\" on channel (\"channel_active\")");
$r = ($r1 && $r2);
}
else {
$r = q("ALTER TABLE `channel` ADD `channel_active` datetime NOT NULL DEFAULT '0001-01-01 00:00:00' ,
ADD INDEX `channel_active` (`channel_active`)");
}
if($r)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
}

26
Zotlabs/Update/_1212.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
namespace Zotlabs\Update;
class _1212 {
function run() {
$r = q("select channel_id from channel where true");
if($r) {
foreach($r as $rv) {
$role = get_pconfig($rv['channel_id'],'system','permissions_role');
if($role !== 'custom') {
$role_permissions = \Zotlabs\Access\PermissionRoles::role_perms($role);
if(array_key_exists('limits',$role_permissions) && array_key_exists('post_comments',$role_permissions['limits'])) {
set_pconfig($rv['channel_id'],'perm_limits','post_comments',$role_permissions['limits']['post_comments']);
}
}
}
}
return UPDATE_SUCCESS;
}
}

28
Zotlabs/Update/_1213.php Normal file
View File

@@ -0,0 +1,28 @@
<?php
namespace Zotlabs\Update;
class _1213 {
function run() {
if(ACTIVE_DBTYPE == DBTYPE_MYSQL) {
q("START TRANSACTION");
$r = q("ALTER TABLE abconfig
DROP INDEX chan,
DROP INDEX xchan,
ADD INDEX chan_xchan (chan, xchan)
");
if($r) {
q("COMMIT");
return UPDATE_SUCCESS;
}
else {
q("ROLLBACK");
return UPDATE_FAILED;
}
}
}
}

57
Zotlabs/Update/_1214.php Normal file
View File

@@ -0,0 +1,57 @@
<?php
namespace Zotlabs\Update;
class _1214 {
function run() {
if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
q("START TRANSACTION");
$r1 = q("ALTER TABLE oauth_clients ALTER COLUMN user_id TYPE bigint USING user_id::bigint");
$r2 = q("ALTER TABLE oauth_clients ALTER COLUMN user_id SET NOT NULL");
$r3 = q("ALTER TABLE oauth_clients ALTER COLUMN user_id SET DEFAULT 0");
$r4 = q("ALTER TABLE oauth_access_tokens ALTER COLUMN user_id TYPE bigint USING user_id::bigint");
$r5 = q("ALTER TABLE oauth_access_tokens ALTER COLUMN user_id SET NOT NULL");
$r6 = q("ALTER TABLE oauth_access_tokens ALTER COLUMN user_id SET DEFAULT 0");
$r7 = q("ALTER TABLE oauth_authorization_codes ALTER COLUMN user_id TYPE bigint USING user_id::bigint");
$r8 = q("ALTER TABLE oauth_authorization_codes ALTER COLUMN user_id SET NOT NULL");
$r9 = q("ALTER TABLE oauth_authorization_codes ALTER COLUMN user_id SET DEFAULT 0");
$r10 = q("ALTER TABLE oauth_refresh_tokens ALTER COLUMN user_id TYPE bigint USING user_id::bigint");
$r11 = q("ALTER TABLE oauth_refresh_tokens ALTER COLUMN user_id SET NOT NULL");
$r12 = q("ALTER TABLE oauth_refresh_tokens ALTER COLUMN user_id SET DEFAULT 0");
if($r1 && $r2 && $r3 && $r4 && $r5 && $r6 && $r7 && $r8 && $r9 && $r10 && $r11 && $r12) {
q("COMMIT");
return UPDATE_SUCCESS;
}
else {
q("ROLLBACK");
return UPDATE_FAILED;
}
}
else {
q("START TRANSACTION");
$r1 = q("ALTER TABLE oauth_clients MODIFY COLUMN user_id int(10) unsigned NOT NULL DEFAULT 0");
$r2 = q("ALTER TABLE oauth_access_tokens MODIFY COLUMN user_id int(10) unsigned NOT NULL DEFAULT 0");
$r3 = q("ALTER TABLE oauth_authorization_codes MODIFY COLUMN user_id int(10) unsigned NOT NULL DEFAULT 0");
$r4 = q("ALTER TABLE oauth_refresh_tokens MODIFY COLUMN user_id int(10) unsigned NOT NULL DEFAULT 0");
if($r1 && $r2 && $r3 && $r4) {
q("COMMIT");
return UPDATE_SUCCESS;
}
else {
q("ROLLBACK");
return UPDATE_FAILED;
}
}
}
}

26
Zotlabs/Update/_1215.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
namespace Zotlabs\Update;
class _1215 {
function run() {
q("START TRANSACTION");
// this will fix mastodon hubloc_url
$r1 = q("UPDATE hubloc SET hubloc_url = LEFT(hubloc_url, POSITION('/users' IN hubloc_url)-1) WHERE POSITION('/users' IN hubloc_url)>0");
// this will fix peertube hubloc_url
$r2 = q("UPDATE hubloc SET hubloc_url = LEFT(hubloc_url, POSITION('/account' IN hubloc_url)-1) WHERE POSITION('/account' IN hubloc_url)>0");
if($r1 && $r2) {
q("COMMIT");
return UPDATE_SUCCESS;
}
else {
q("ROLLBACK");
return UPDATE_FAILED;
}
}
}

View File

@@ -3,16 +3,24 @@
namespace Zotlabs\Web;
/**
* Implements HTTP Signatures per draft-cavage-http-signatures-07
* @brief Implements HTTP Signatures per draft-cavage-http-signatures-07.
*
* @see https://tools.ietf.org/html/draft-cavage-http-signatures-07
*/
class HTTPSig {
// See RFC5843
static function generate_digest($body,$set = true) {
$digest = base64_encode(hash('sha256',$body,true));
/**
* @brief RFC5843
*
* @see https://tools.ietf.org/html/rfc5843
*
* @param string $body The value to create the digest for
* @param boolean $set (optional, default true)
* If set send a Digest HTTP header
* @return string The generated digest of $body
*/
static function generate_digest($body, $set = true) {
$digest = base64_encode(hash('sha256', $body, true));
if($set) {
header('Digest: SHA-256=' . $digest);
@@ -40,6 +48,7 @@ class HTTPSig {
if(is_array($data) && $data['header']) {
if(! $data['success'])
return $result;
$h = new \Zotlabs\Web\HTTPHeaders($data['header']);
$headers = $h->fetcharr();
$body = $data['body'];
@@ -47,9 +56,11 @@ class HTTPSig {
else {
$headers = [];
$headers['(request-target)'] =
$headers['(request-target)'] =
strtolower($_SERVER['REQUEST_METHOD']) . ' ' .
$_SERVER['REQUEST_URI'];
$headers['content-type'] = $_SERVER['CONTENT_TYPE'];
foreach($_SERVER as $k => $v) {
if(strpos($k,'HTTP_') === 0) {
$field = str_replace('_','-',strtolower(substr($k,5)));
@@ -58,6 +69,10 @@ class HTTPSig {
}
}
// logger('SERVER: ' . print_r($_SERVER,true), LOGGER_ALL);
// logger('headers: ' . print_r($headers,true), LOGGER_ALL);
$sig_block = null;
if(array_key_exists('signature',$headers)) {
@@ -78,7 +93,7 @@ class HTTPSig {
$result['header_signed'] = true;
$signed_headers = $sig_block['headers'];
if(! $signed_headers)
if(! $signed_headers)
$signed_headers = [ 'date' ];
$signed_data = '';
@@ -131,7 +146,7 @@ class HTTPSig {
if($digest[0] === 'SHA-512')
$hashalg = 'sha512';
// The explode operation will have stripped the '=' padding, so compare against unpadded base64
// The explode operation will have stripped the '=' padding, so compare against unpadded base64
if(rtrim(base64_encode(hash($hashalg,$body,true)),'=') === $digest[1]) {
$result['content_valid'] = true;
}
@@ -146,7 +161,7 @@ class HTTPSig {
if($digest[0] === 'SHA-512')
$hashalg = 'sha512';
// The explode operation will have stripped the '=' padding, so compare against unpadded base64
// The explode operation will have stripped the '=' padding, so compare against unpadded base64
if(rtrim(base64_encode(hash($hashalg,$_POST['data'],true)),'=') === $digest[1]) {
$result['content_valid'] = true;
}
@@ -155,9 +170,15 @@ class HTTPSig {
logger('Content_Valid: ' . (($result['content_valid']) ? 'true' : 'false'));
return $result;
}
/**
* @brief
*
* @param string $id
* @return boolean|string
* false if no pub key found, otherwise return the pub key
*/
function get_activitypub_key($id) {
if(strpos($id,'acct:') === 0) {
@@ -174,25 +195,41 @@ class HTTPSig {
if($x && $x[0]['xchan_pubkey']) {
return ($x[0]['xchan_pubkey']);
}
$r = as_fetch($id);
if(function_exists('as_fetch'))
$r = as_fetch($id);
if($r) {
$j = json_decode($r,true);
if($j['id'] !== $id)
return false;
if(array_key_exists('publicKey',$j) && array_key_exists('publicKeyPem',$j['publicKey'])) {
if((array_key_exists('id',$j['publicKey']) && $j['publicKey']['id'] !== $id) && $j['id'] !== $id)
return false;
return($j['publicKey']['publicKeyPem']);
}
}
return false;
}
static function create_sig($request,$head,$prvkey,$keyid = 'Key',$send_headers = false,$auth = false,$alg = 'sha256',
$crypt_key = null, $crypt_algo = 'aes256ctr') {
/**
* @brief
*
* @param string $request
* @param array $head
* @param string $prvkey
* @param string $keyid (optional, default 'Key')
* @param boolean $send_headers (optional, default false)
* If set send a HTTP header
* @param boolean $auth (optional, default false)
* @param string $alg (optional, default 'sha256')
* @param string $crypt_key (optional, default null)
* @param string $crypt_algo (optional, default 'aes256ctr')
* @return array
*/
static function create_sig($request, $head, $prvkey, $keyid = 'Key', $send_headers = false, $auth = false,
$alg = 'sha256', $crypt_key = null, $crypt_algo = 'aes256ctr') {
$return_headers = [];
@@ -212,7 +249,7 @@ class HTTPSig {
$x = crypto_encapsulate($headerval,$crypt_key,$crypt_algo);
$headerval = 'iv="' . $x['iv'] . '",key="' . $x['key'] . '",alg="' . $x['alg'] . '",data="' . $x['data'] . '"';
}
if($auth) {
$sighead = 'Authorization: Signature ' . $headerval;
}
@@ -236,12 +273,20 @@ class HTTPSig {
else {
$return_headers[] = $sighead;
}
return $return_headers;
}
static function sign($request,$head,$prvkey,$alg = 'sha256') {
/**
* @brief
*
* @param string $request
* @param array $head
* @param string $prvkey
* @param string $alg (optional) default 'sha256'
* @return array
*/
static function sign($request, $head, $prvkey, $alg = 'sha256') {
$ret = [];
@@ -250,27 +295,38 @@ class HTTPSig {
if($request) {
$headers = '(request-target)' . ': ' . trim($request) . "\n";
$fields = '(request-target)';
}
}
if($head) {
foreach($head as $k => $v) {
$headers .= strtolower($k) . ': ' . trim($v) . "\n";
if($fields)
$fields .= ' ';
$fields .= strtolower($k);
}
// strip the trailing linefeed
$headers = rtrim($headers,"\n");
}
$sig = base64_encode(rsa_sign($headers,$prvkey,$alg));
$sig = base64_encode(rsa_sign($headers,$prvkey,$alg));
$ret['headers'] = $fields;
$ret['signature'] = $sig;
return $ret;
}
/**
* @brief
*
* @param string $header
* @return array associate array with
* - \e string \b keyID
* - \e string \b algorithm
* - \e array \b headers
* - \e string \b signature
*/
static function parse_sigheader($header) {
$ret = [];
@@ -297,12 +353,23 @@ class HTTPSig {
}
static function decrypt_sigheader($header,$prvkey = null) {
/**
* @brief
*
* @param string $header
* @param string $prvkey (optional), if not set use site private key
* @return array|string associative array, empty string if failue
* - \e string \b iv
* - \e string \b key
* - \e string \b alg
* - \e string \b data
*/
static function decrypt_sigheader($header, $prvkey = null) {
$iv = $key = $alg = $data = null;
if(! $prvkey) {
$prvkey = get_config('system','prvkey');
$prvkey = get_config('system', 'prvkey');
}
$matches = [];
@@ -319,10 +386,8 @@ class HTTPSig {
if($iv && $key && $alg && $data) {
return crypto_unencapsulate([ 'iv' => $iv, 'key' => $key, 'alg' => $alg, 'data' => $data ] , $prvkey);
}
return '';
return '';
}
}

View File

@@ -44,9 +44,9 @@ class WebServer {
* We have to do it here because the session was just now opened.
*/
if(array_key_exists('system_language',$_POST)) {
if(strlen($_POST['system_language']))
$_SESSION['language'] = $_POST['system_language'];
if(array_key_exists('system_language',$_REQUEST)) {
if(strlen($_REQUEST['system_language']))
$_SESSION['language'] = $_REQUEST['system_language'];
else
unset($_SESSION['language']);
}

View File

@@ -0,0 +1,46 @@
<?php
namespace Zotlabs\Widget;
class Catcloud {
function widget($arr) {
if((! \App::$profile['profile_uid']) || (! \App::$profile['channel_hash']))
return '';
$limit = ((array_key_exists('limit',$arr)) ? intval($arr['limit']) : 50);
if(array_key_exists('type',$arr)) {
switch($arr['type']) {
case 'cards':
if(! perm_is_allowed(\App::$profile['profile_uid'], get_observer_hash(), 'view_pages'))
return '';
return card_catblock(\App::$profile['profile_uid'], $limit, '', \App::$profile['channel_hash']);
case 'articles':
if(! perm_is_allowed(\App::$profile['profile_uid'], get_observer_hash(), 'view_pages'))
return '';
return article_catblock(\App::$profile['profile_uid'], $limit, '', \App::$profile['channel_hash']);
default:
break;
}
}
if(! perm_is_allowed(\App::$profile['profile_uid'], get_observer_hash(), 'view_stream'))
return '';
return catblock(\App::$profile['profile_uid'], $limit, '', \App::$profile['channel_hash']);
}
}

View File

@@ -6,16 +6,9 @@ class Design_tools {
function widget($arr) {
// mod menu doesn't load a profile. For any modules which load a profile, check it.
// otherwise local_channel() is sufficient for permissions.
if(perm_is_allowed(\App::$profile['profile_uid'],get_observer_hash(),'write_pages') || (\App::$is_sys && is_site_admin()))
return design_tools();
if(\App::$profile['profile_uid'])
if((\App::$profile['profile_uid'] != local_channel()) && (! \App::$is_sys))
return '';
if(! local_channel())
return '';
return design_tools();
return EMPTY_STR;
}
}

View File

@@ -51,7 +51,7 @@ class Forums {
$r1 = q("select abook_id, xchan_hash, xchan_name, xchan_url, xchan_photo_s from abook left join xchan on abook_xchan = xchan_hash where xchan_deleted = 0 and abook_channel = %d and abook_pending = 0 and abook_ignored = 0 and abook_blocked = 0 $sql_extra order by xchan_name $limit ",
$r1 = q("select abook_id, xchan_hash, xchan_name, xchan_url, xchan_photo_s from abook left join xchan on abook_xchan = xchan_hash where xchan_deleted = 0 and abook_channel = %d and abook_pending = 0 and abook_ignored = 0 and abook_blocked = 0 and abook_archived = 0 $sql_extra order by xchan_name $limit ",
intval(local_channel())
);
@@ -66,8 +66,8 @@ class Forums {
for($x = 0; $x < count($r1); $x ++) {
$r = q("select sum(item_unseen) as unseen from item
where uid = %d and owner_xchan = '%s' and item_unseen = 1 $perms_sql ",
dbesc($r1[$x]['xchan_hash']),
intval(local_channel())
intval(local_channel()),
dbesc($r1[$x]['xchan_hash'])
);
if($r)
$r1[$x]['unseen'] = $r[0]['unseen'];

View File

@@ -13,22 +13,13 @@ class Newmember {
if(! $c)
return EMPTY_STR;
$a = \App::get_account();
if(! $a)
return EMPTY_STR;
if(datetime_convert('UTC','UTC',$a['account_created']) < datetime_convert('UTC','UTC', 'now - 60 days'))
if(! feature_enabled(local_channel(),'start_menu'))
return EMPTY_STR;
// This could be a new account that was used to clone a very old channel
$ob = \App::get_observer();
if($ob && array_key_exists('xchan_name_date',$ob) && $ob['xchan_name_date'] < datetime_convert('UTC','UTC','now - 60 days'))
return EMPTY_STR;
$options = [
t('Profile Creation'),
[
@@ -46,7 +37,7 @@ class Newmember {
t('Communicate'),
[
'channel/' . $channel['channel_address'] => t('View your channel homepage'),
'channel/' . $c['channel_address'] => t('View your channel homepage'),
'network' => t('View your network stream'),
],

View File

@@ -123,7 +123,7 @@ class Notifications {
];
}
if(get_config('system', 'disable_discover_tab') != 1) {
if(can_view_public_stream()) {
$notifications[] = [
'type' => 'pubs',
'icon' => 'globe',

View File

@@ -0,0 +1,41 @@
<?php
namespace Zotlabs\Widget;
class Pubtagcloud {
function widget($arr) {
$trending = ((array_key_exists('trending',$arr)) ? intval($arr['trending']) : 0);
if((observer_prohibited(true))) {
return EMPTY_STR;
}
if(! intval(get_config('system','open_pubstream',1))) {
if(! get_observer_hash()) {
return EMPTY_STR;
}
}
$site_firehose = ((intval(get_config('system','site_firehose',0))) ? true : false);
$net_firehose = ((get_config('system','disable_discover_tab',1)) ? false : true);
if(! ($site_firehose || $net_firehose)) {
return EMPTY_STR;
}
if($net_firehose) {
$site_firehose = false;
}
$safemode = get_xconfig(get_observer_hash(),'directory','safemode',1);
$limit = ((array_key_exists('limit', $arr)) ? intval($arr['limit']) : 75);
return pubtagblock($net_firehose,$site_firehose, $limit, $trending, $safemode);
return '';
}
}

View File

@@ -81,12 +81,20 @@ class Settings_menu {
if(feature_enabled(local_channel(),'oauth_clients')) {
$tabs[] = array(
'label' => t('Connected apps'),
'label' => t('OAuth1 apps'),
'url' => z_root() . '/settings/oauth',
'selected' => ((argv(1) === 'oauth') ? 'active' : ''),
);
}
if(feature_enabled(local_channel(),'oauth2_clients')) {
$tabs[] = array(
'label' => t('OAuth2 apps'),
'url' => z_root() . '/settings/oauth2',
'selected' => ((argv(1) === 'oauth2') ? 'active' : ''),
);
}
if(feature_enabled(local_channel(),'access_tokens')) {
$tabs[] = array(
'label' => t('Guest Access Tokens'),

View File

@@ -2,9 +2,6 @@
namespace Zotlabs\Widget;
// @FIXME The problem with this widget is that we don't have a search function for webpages
// that we can send the links to. Then we should also provide an option to search webpages
// and conversations.
class Tagcloud {
@@ -14,15 +11,15 @@ class Tagcloud {
$uid = \App::$profile_uid;
$count = ((x($args,'count')) ? intval($args['count']) : 24);
$flags = 0;
$type = TERM_CATEGORY;
$type = TERM_HASHTAG;
// @FIXME there exists no $authors variable
$r = tagadelic($uid, $count, $authors, $owner, $flags, ITEM_TYPE_WEBPAGE, $type);
$r = tagadelic($uid, $count, $authors, $owner, $flags, 0, $type);
// @FIXME this should use a template
if($r) {
$o = '<div class="tagblock widget"><h3>' . t('Categories') . '</h3><div class="tags" align="center">';
$o = '<div class="tagblock widget"><h3>' . t('Tags') . '</h3><div class="tags" align="center">';
foreach($r as $rv) {
$o .= '<span class="tag' . $rv[2] . '">' . $rv[0] .' </span> ' . "\r\n";
}

View File

@@ -21,7 +21,7 @@ class Tasklist {
</script>';
$o .= '<div class="widget">' . '<h3>' . t('Tasks') . '</h3><div class="tasklist-tasks">';
$o .= '</div><form id="tasklist-new-form" action="" ><input id="tasklist-new-summary" type="text" name="summary" value="" /></form>';
$o .= '</div><form id="tasklist-new-form" action="" ><input class="form-control" id="tasklist-new-summary" type="text" name="summary" value="" /></form>';
$o .= '</div>';
return $o;

View File

@@ -1,5 +1,5 @@
version: 1
url: https://github.com/redmatrix/hubzilla/issues
version: 2
url: https://framagit.org/hubzilla/core/issues
name: Report Bug
photo: icon:bug
categories: System

View File

@@ -50,9 +50,11 @@ require_once('include/attach.php');
require_once('include/bbcode.php');
define ( 'PLATFORM_NAME', 'hubzilla' );
define ( 'STD_VERSION', '3.2' );
define ( 'ZOT_REVISION', '1.3' );
define ( 'DB_UPDATE_VERSION', 1207 );
define ( 'STD_VERSION', '3.4.2' );
define ( 'ZOT_REVISION', '6.0a' );
define ( 'DB_UPDATE_VERSION', 1215 );
define ( 'PROJECT_BASE', __DIR__ );
@@ -79,11 +81,11 @@ define ( 'DIRECTORY_MODE_STANDALONE', 0x0100); // A detached (off the grid) hub
// point to go out and find the rest of the world.
define ( 'DIRECTORY_REALM', 'RED_GLOBAL');
define ( 'DIRECTORY_FALLBACK_MASTER', 'https://gravizot.de');
define ( 'DIRECTORY_FALLBACK_MASTER', 'https://zotadel.net');
$DIRECTORY_FALLBACK_SERVERS = array(
'https://hubzilla.zottel.net',
'https://gravizot.de'
'https://zotadel.net'
);
@@ -401,6 +403,7 @@ define ( 'VNOTIFY_INTRO', 0x0200 );
define ( 'VNOTIFY_REGISTER', 0x0400 );
define ( 'VNOTIFY_FILES', 0x0800 );
define ( 'VNOTIFY_PUBS', 0x1000 );
define ( 'VNOTIFY_LIKE', 0x2000 );
@@ -477,6 +480,7 @@ define ( 'ACTIVITY_ABSTAIN', NAMESPACE_ZOT . '/activity/abstain' );
define ( 'ACTIVITY_ATTEND', NAMESPACE_ZOT . '/activity/attendyes' );
define ( 'ACTIVITY_ATTENDNO', NAMESPACE_ZOT . '/activity/attendno' );
define ( 'ACTIVITY_ATTENDMAYBE', NAMESPACE_ZOT . '/activity/attendmaybe' );
define ( 'ACTIVITY_POLLRESPONSE', NAMESPACE_ZOT . '/activity/pollresponse' );
define ( 'ACTIVITY_OBJ_HEART', NAMESPACE_ZOT . '/activity/heart' );
@@ -854,7 +858,7 @@ class App {
self::$scheme = 'https';
if(x($_SERVER,'SERVER_NAME')) {
self::$hostname = $_SERVER['SERVER_NAME'];
self::$hostname = punify($_SERVER['SERVER_NAME']);
if(x($_SERVER,'SERVER_PORT') && $_SERVER['SERVER_PORT'] != 80 && $_SERVER['SERVER_PORT'] != 443)
self::$hostname .= ':' . $_SERVER['SERVER_PORT'];
@@ -871,13 +875,13 @@ class App {
set_include_path("include/self::$hostname" . PATH_SEPARATOR . get_include_path());
if((x($_SERVER,'QUERY_STRING')) && substr($_SERVER['QUERY_STRING'], 0, 2) === "q=") {
self::$query_string = substr($_SERVER['QUERY_STRING'], 2);
self::$query_string = escape_tags(substr($_SERVER['QUERY_STRING'], 2));
// removing trailing / - maybe a nginx problem
if (substr(self::$query_string, 0, 1) == "/")
self::$query_string = substr(self::$query_string, 1);
}
if(x($_GET,'q'))
self::$cmd = trim($_GET['q'],'/\\');
self::$cmd = escape_tags(trim($_GET['q'],'/\\'));
// unix style "homedir"
@@ -951,6 +955,9 @@ class App {
&& is_array(self::$config['system'])
&& array_key_exists('baseurl',self::$config['system'])
&& strlen(self::$config['system']['baseurl'])) {
// get_baseurl() is a heavily used function.
// Do not use punify() here until we find a library that performs better than what we have now.
//$url = punify(self::$config['system']['baseurl']);
$url = self::$config['system']['baseurl'];
$url = trim($url,'\\/');
return $url;
@@ -958,7 +965,7 @@ class App {
$scheme = self::$scheme;
self::$baseurl = $scheme . "://" . self::$hostname . ((isset(self::$path) && strlen(self::$path)) ? '/' . self::$path : '' );
self::$baseurl = $scheme . "://" . punify(self::$hostname) . ((isset(self::$path) && strlen(self::$path)) ? '/' . self::$path : '' );
return self::$baseurl;
}
@@ -969,7 +976,7 @@ class App {
&& is_array(self::$config['system'])
&& array_key_exists('baseurl',self::$config['system'])
&& strlen(self::$config['system']['baseurl'])) {
$url = self::$config['system']['baseurl'];
$url = punify(self::$config['system']['baseurl']);
$url = trim($url,'\\/');
}
@@ -980,7 +987,7 @@ class App {
if($parsed !== false) {
self::$scheme = $parsed['scheme'];
self::$hostname = $parsed['host'];
self::$hostname = punify($parsed['host']);
if(x($parsed,'port'))
self::$hostname .= ':' . $parsed['port'];
if(x($parsed,'path'))

264
composer.lock generated
View File

@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"content-hash": "73ca170baa6ded94a989b8a1066e6a98",
"content-hash": "516114a0fbd804e5234ebeacbac30376",
"packages": [
{
"name": "bshaffer/oauth2-server-php",
@@ -66,16 +66,16 @@
},
{
"name": "commerceguys/intl",
"version": "v0.7.4",
"version": "v0.7.5",
"source": {
"type": "git",
"url": "https://github.com/commerceguys/intl.git",
"reference": "edfcfc26ed8505c4f6fcf862eb36dfda1af74b00"
"reference": "de1435502068393fae4061818e194e4ea61b98d6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/commerceguys/intl/zipball/edfcfc26ed8505c4f6fcf862eb36dfda1af74b00",
"reference": "edfcfc26ed8505c4f6fcf862eb36dfda1af74b00",
"url": "https://api.github.com/repos/commerceguys/intl/zipball/de1435502068393fae4061818e194e4ea61b98d6",
"reference": "de1435502068393fae4061818e194e4ea61b98d6",
"shasum": ""
},
"require": {
@@ -106,20 +106,20 @@
}
],
"description": "Internationalization library powered by CLDR data.",
"time": "2016-12-13T12:33:19+00:00"
"time": "2017-12-29T00:13:05+00:00"
},
{
"name": "ezyang/htmlpurifier",
"version": "v4.9.3",
"version": "v4.10.0",
"source": {
"type": "git",
"url": "https://github.com/ezyang/htmlpurifier.git",
"reference": "95e1bae3182efc0f3422896a3236e991049dac69"
"reference": "d85d39da4576a6934b72480be6978fb10c860021"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/ezyang/htmlpurifier/zipball/95e1bae3182efc0f3422896a3236e991049dac69",
"reference": "95e1bae3182efc0f3422896a3236e991049dac69",
"url": "https://api.github.com/repos/ezyang/htmlpurifier/zipball/d85d39da4576a6934b72480be6978fb10c860021",
"reference": "d85d39da4576a6934b72480be6978fb10c860021",
"shasum": ""
},
"require": {
@@ -153,7 +153,7 @@
"keywords": [
"html"
],
"time": "2017-06-03T02:28:16+00:00"
"time": "2018-02-23T01:58:20+00:00"
},
{
"name": "league/html-to-markdown",
@@ -256,30 +256,25 @@
},
{
"name": "michelf/php-markdown",
"version": "1.7.0",
"version": "1.8.0",
"source": {
"type": "git",
"url": "https://github.com/michelf/php-markdown.git",
"reference": "1f51cc520948f66cd2af8cbc45a5ee175e774220"
"reference": "01ab082b355bf188d907b9929cd99b2923053495"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/michelf/php-markdown/zipball/1f51cc520948f66cd2af8cbc45a5ee175e774220",
"reference": "1f51cc520948f66cd2af8cbc45a5ee175e774220",
"url": "https://api.github.com/repos/michelf/php-markdown/zipball/01ab082b355bf188d907b9929cd99b2923053495",
"reference": "01ab082b355bf188d907b9929cd99b2923053495",
"shasum": ""
},
"require": {
"php": ">=5.3.0"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-lib": "1.4.x-dev"
}
},
"autoload": {
"psr-0": {
"Michelf": ""
"psr-4": {
"Michelf\\": "Michelf/"
}
},
"notification-url": "https://packagist.org/downloads/",
@@ -303,7 +298,7 @@
"keywords": [
"markdown"
],
"time": "2016-10-29T18:58:20+00:00"
"time": "2018-01-15T00:49:33+00:00"
},
{
"name": "pear/text_languagedetect",
@@ -538,16 +533,16 @@
},
{
"name": "sabre/http",
"version": "4.2.3",
"version": "v4.2.4",
"source": {
"type": "git",
"url": "https://github.com/sabre-io/http.git",
"reference": "0295f9a3ee39be97e0898592fc19e42421e0cd93"
"reference": "acccec4ba863959b2d10c1fa0fb902736c5c8956"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sabre-io/http/zipball/0295f9a3ee39be97e0898592fc19e42421e0cd93",
"reference": "0295f9a3ee39be97e0898592fc19e42421e0cd93",
"url": "https://api.github.com/repos/sabre-io/http/zipball/acccec4ba863959b2d10c1fa0fb902736c5c8956",
"reference": "acccec4ba863959b2d10c1fa0fb902736c5c8956",
"shasum": ""
},
"require": {
@@ -590,7 +585,7 @@
"keywords": [
"http"
],
"time": "2017-06-12T07:53:04+00:00"
"time": "2018-02-23T11:10:29+00:00"
},
{
"name": "sabre/uri",
@@ -645,16 +640,16 @@
},
{
"name": "sabre/vobject",
"version": "4.1.3",
"version": "4.1.5",
"source": {
"type": "git",
"url": "https://github.com/sabre-io/vobject.git",
"reference": "df9916813d1d83e4f761c4cba13361ee74196fac"
"reference": "0928660e92d46d2d24336a6db320636aa3a75414"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sabre-io/vobject/zipball/df9916813d1d83e4f761c4cba13361ee74196fac",
"reference": "df9916813d1d83e4f761c4cba13361ee74196fac",
"url": "https://api.github.com/repos/sabre-io/vobject/zipball/0928660e92d46d2d24336a6db320636aa3a75414",
"reference": "0928660e92d46d2d24336a6db320636aa3a75414",
"shasum": ""
},
"require": {
@@ -663,7 +658,7 @@
"sabre/xml": ">=1.5 <3.0"
},
"require-dev": {
"phpunit/phpunit": "> 4.8, <6.0.0",
"phpunit/phpunit": "> 4.8.35, <6.0.0",
"sabre/cs": "^1.0.0"
},
"suggest": {
@@ -738,7 +733,7 @@
"xCal",
"xCard"
],
"time": "2017-10-18T08:29:40+00:00"
"time": "2018-03-08T21:06:39+00:00"
},
{
"name": "sabre/xml",
@@ -1179,16 +1174,16 @@
},
{
"name": "behat/mink-extension",
"version": "2.3.0",
"version": "2.3.1",
"source": {
"type": "git",
"url": "https://github.com/Behat/MinkExtension.git",
"reference": "badc565b7a1d05c4a4bf49c789045bcf7af6c6de"
"reference": "80f7849ba53867181b7e412df9210e12fba50177"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/Behat/MinkExtension/zipball/badc565b7a1d05c4a4bf49c789045bcf7af6c6de",
"reference": "badc565b7a1d05c4a4bf49c789045bcf7af6c6de",
"url": "https://api.github.com/repos/Behat/MinkExtension/zipball/80f7849ba53867181b7e412df9210e12fba50177",
"reference": "80f7849ba53867181b7e412df9210e12fba50177",
"shasum": ""
},
"require": {
@@ -1234,7 +1229,7 @@
"test",
"web"
],
"time": "2017-11-24T19:30:49+00:00"
"time": "2018-02-06T15:36:30+00:00"
},
{
"name": "behat/mink-goutte-driver",
@@ -2024,35 +2019,29 @@
},
{
"name": "phpdocumentor/reflection-docblock",
"version": "4.2.0",
"version": "3.3.2",
"source": {
"type": "git",
"url": "https://github.com/phpDocumentor/ReflectionDocBlock.git",
"reference": "66465776cfc249844bde6d117abff1d22e06c2da"
"reference": "bf329f6c1aadea3299f08ee804682b7c45b326a2"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/66465776cfc249844bde6d117abff1d22e06c2da",
"reference": "66465776cfc249844bde6d117abff1d22e06c2da",
"url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/bf329f6c1aadea3299f08ee804682b7c45b326a2",
"reference": "bf329f6c1aadea3299f08ee804682b7c45b326a2",
"shasum": ""
},
"require": {
"php": "^7.0",
"php": "^5.6 || ^7.0",
"phpdocumentor/reflection-common": "^1.0.0",
"phpdocumentor/type-resolver": "^0.4.0",
"webmozart/assert": "^1.0"
},
"require-dev": {
"doctrine/instantiator": "~1.0.5",
"mockery/mockery": "^1.0",
"phpunit/phpunit": "^6.4"
"mockery/mockery": "^0.9.4",
"phpunit/phpunit": "^4.4"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "4.x-dev"
}
},
"autoload": {
"psr-4": {
"phpDocumentor\\Reflection\\": [
@@ -2071,7 +2060,7 @@
}
],
"description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.",
"time": "2017-11-27T17:38:31+00:00"
"time": "2017-11-10T14:09:06+00:00"
},
{
"name": "phpdocumentor/type-resolver",
@@ -2122,16 +2111,16 @@
},
{
"name": "phpspec/prophecy",
"version": "1.7.3",
"version": "1.7.5",
"source": {
"type": "git",
"url": "https://github.com/phpspec/prophecy.git",
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf"
"reference": "dfd6be44111a7c41c2e884a336cc4f461b3b2401"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpspec/prophecy/zipball/e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
"url": "https://api.github.com/repos/phpspec/prophecy/zipball/dfd6be44111a7c41c2e884a336cc4f461b3b2401",
"reference": "dfd6be44111a7c41c2e884a336cc4f461b3b2401",
"shasum": ""
},
"require": {
@@ -2143,7 +2132,7 @@
},
"require-dev": {
"phpspec/phpspec": "^2.5|^3.2",
"phpunit/phpunit": "^4.8.35 || ^5.7"
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5"
},
"type": "library",
"extra": {
@@ -2181,20 +2170,20 @@
"spy",
"stub"
],
"time": "2017-11-24T13:59:53+00:00"
"time": "2018-02-19T10:16:54+00:00"
},
{
"name": "phpunit/dbunit",
"version": "3.0.2",
"version": "3.0.3",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/dbunit.git",
"reference": "403350339b6aca748ee0067d027d85621992e21f"
"reference": "0fa4329e490480ab957fe7b1185ea0996ca11f44"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/dbunit/zipball/403350339b6aca748ee0067d027d85621992e21f",
"reference": "403350339b6aca748ee0067d027d85621992e21f",
"url": "https://api.github.com/repos/sebastianbergmann/dbunit/zipball/0fa4329e490480ab957fe7b1185ea0996ca11f44",
"reference": "0fa4329e490480ab957fe7b1185ea0996ca11f44",
"shasum": ""
},
"require": {
@@ -2233,7 +2222,7 @@
"testing",
"xunit"
],
"time": "2017-11-18T17:40:34+00:00"
"time": "2018-01-23T13:32:26+00:00"
},
{
"name": "phpunit/php-code-coverage",
@@ -2773,21 +2762,21 @@
},
{
"name": "sebastian/comparator",
"version": "2.1.0",
"version": "2.1.3",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/comparator.git",
"reference": "1174d9018191e93cb9d719edec01257fc05f8158"
"reference": "34369daee48eafb2651bea869b4b15d75ccc35f9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1174d9018191e93cb9d719edec01257fc05f8158",
"reference": "1174d9018191e93cb9d719edec01257fc05f8158",
"url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/34369daee48eafb2651bea869b4b15d75ccc35f9",
"reference": "34369daee48eafb2651bea869b4b15d75ccc35f9",
"shasum": ""
},
"require": {
"php": "^7.0",
"sebastian/diff": "^2.0",
"sebastian/diff": "^2.0 || ^3.0",
"sebastian/exporter": "^3.1"
},
"require-dev": {
@@ -2833,7 +2822,7 @@
"compare",
"equality"
],
"time": "2017-11-03T07:16:52+00:00"
"time": "2018-02-01T13:46:46+00:00"
},
{
"name": "sebastian/diff",
@@ -3287,16 +3276,16 @@
},
{
"name": "symfony/browser-kit",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/browser-kit.git",
"reference": "f761b4ecdd23a451c2cae6fba704d8b207cbb045"
"reference": "490f27762705c8489bd042fe3e9377a191dba9b4"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/browser-kit/zipball/f761b4ecdd23a451c2cae6fba704d8b207cbb045",
"reference": "f761b4ecdd23a451c2cae6fba704d8b207cbb045",
"url": "https://api.github.com/repos/symfony/browser-kit/zipball/490f27762705c8489bd042fe3e9377a191dba9b4",
"reference": "490f27762705c8489bd042fe3e9377a191dba9b4",
"shasum": ""
},
"require": {
@@ -3340,20 +3329,20 @@
],
"description": "Symfony BrowserKit Component",
"homepage": "https://symfony.com",
"time": "2017-12-11T22:06:16+00:00"
"time": "2018-01-03T07:37:34+00:00"
},
{
"name": "symfony/class-loader",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/class-loader.git",
"reference": "e8d36a7b5568d232f5c3f8ef92665836b9f1e038"
"reference": "e63c12699822bb3b667e7216ba07fbcc3a3e203e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/class-loader/zipball/e8d36a7b5568d232f5c3f8ef92665836b9f1e038",
"reference": "e8d36a7b5568d232f5c3f8ef92665836b9f1e038",
"url": "https://api.github.com/repos/symfony/class-loader/zipball/e63c12699822bb3b667e7216ba07fbcc3a3e203e",
"reference": "e63c12699822bb3b667e7216ba07fbcc3a3e203e",
"shasum": ""
},
"require": {
@@ -3396,20 +3385,20 @@
],
"description": "Symfony ClassLoader Component",
"homepage": "https://symfony.com",
"time": "2017-11-05T16:10:10+00:00"
"time": "2018-01-03T07:37:34+00:00"
},
{
"name": "symfony/config",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/config.git",
"reference": "e57211b88aa889fefac1cb36866db04100b0f21c"
"reference": "05e10567b529476a006b00746c5f538f1636810e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/config/zipball/e57211b88aa889fefac1cb36866db04100b0f21c",
"reference": "e57211b88aa889fefac1cb36866db04100b0f21c",
"url": "https://api.github.com/repos/symfony/config/zipball/05e10567b529476a006b00746c5f538f1636810e",
"reference": "05e10567b529476a006b00746c5f538f1636810e",
"shasum": ""
},
"require": {
@@ -3422,6 +3411,7 @@
},
"require-dev": {
"symfony/dependency-injection": "~3.3|~4.0",
"symfony/event-dispatcher": "~3.3|~4.0",
"symfony/finder": "~3.3|~4.0",
"symfony/yaml": "~3.0|~4.0"
},
@@ -3458,20 +3448,20 @@
],
"description": "Symfony Config Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-14T10:03:57+00:00"
},
{
"name": "symfony/console",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/console.git",
"reference": "9f21adfb92a9315b73ae2ed43138988ee4913d4e"
"reference": "067339e9b8ec30d5f19f5950208893ff026b94f7"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/console/zipball/9f21adfb92a9315b73ae2ed43138988ee4913d4e",
"reference": "9f21adfb92a9315b73ae2ed43138988ee4913d4e",
"url": "https://api.github.com/repos/symfony/console/zipball/067339e9b8ec30d5f19f5950208893ff026b94f7",
"reference": "067339e9b8ec30d5f19f5950208893ff026b94f7",
"shasum": ""
},
"require": {
@@ -3527,20 +3517,20 @@
],
"description": "Symfony Console Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-26T15:46:28+00:00"
},
{
"name": "symfony/css-selector",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/css-selector.git",
"reference": "eac760b414cf1f64362c3dd047b989e4db121332"
"reference": "544655f1fc078a9cd839fdda2b7b1e64627c826a"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/css-selector/zipball/eac760b414cf1f64362c3dd047b989e4db121332",
"reference": "eac760b414cf1f64362c3dd047b989e4db121332",
"url": "https://api.github.com/repos/symfony/css-selector/zipball/544655f1fc078a9cd839fdda2b7b1e64627c826a",
"reference": "544655f1fc078a9cd839fdda2b7b1e64627c826a",
"shasum": ""
},
"require": {
@@ -3580,20 +3570,20 @@
],
"description": "Symfony CssSelector Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-03T14:55:07+00:00"
},
{
"name": "symfony/debug",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/debug.git",
"reference": "543deab3ffff94402440b326fc94153bae2dfa7a"
"reference": "9b1071f86e79e1999b3d3675d2e0e7684268b9bc"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/debug/zipball/543deab3ffff94402440b326fc94153bae2dfa7a",
"reference": "543deab3ffff94402440b326fc94153bae2dfa7a",
"url": "https://api.github.com/repos/symfony/debug/zipball/9b1071f86e79e1999b3d3675d2e0e7684268b9bc",
"reference": "9b1071f86e79e1999b3d3675d2e0e7684268b9bc",
"shasum": ""
},
"require": {
@@ -3636,20 +3626,20 @@
],
"description": "Symfony Debug Component",
"homepage": "https://symfony.com",
"time": "2017-12-12T08:27:14+00:00"
"time": "2018-02-28T21:49:22+00:00"
},
{
"name": "symfony/dependency-injection",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/dependency-injection.git",
"reference": "5f81907ea43bfa971ac2c7fbac593ebe7cd7d333"
"reference": "12e901abc1cb0d637a0e5abe9923471361d96b07"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/5f81907ea43bfa971ac2c7fbac593ebe7cd7d333",
"reference": "5f81907ea43bfa971ac2c7fbac593ebe7cd7d333",
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/12e901abc1cb0d637a0e5abe9923471361d96b07",
"reference": "12e901abc1cb0d637a0e5abe9923471361d96b07",
"shasum": ""
},
"require": {
@@ -3707,20 +3697,20 @@
],
"description": "Symfony DependencyInjection Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-03-04T03:54:53+00:00"
},
{
"name": "symfony/dom-crawler",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/dom-crawler.git",
"reference": "dc847845c66fa68ad4522ed27e62b9b9dd12ab3b"
"reference": "2bb5d3101cc01f4fe580e536daf4f1959bc2d24d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/dom-crawler/zipball/dc847845c66fa68ad4522ed27e62b9b9dd12ab3b",
"reference": "dc847845c66fa68ad4522ed27e62b9b9dd12ab3b",
"url": "https://api.github.com/repos/symfony/dom-crawler/zipball/2bb5d3101cc01f4fe580e536daf4f1959bc2d24d",
"reference": "2bb5d3101cc01f4fe580e536daf4f1959bc2d24d",
"shasum": ""
},
"require": {
@@ -3763,20 +3753,20 @@
],
"description": "Symfony DomCrawler Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-22T10:48:49+00:00"
},
{
"name": "symfony/event-dispatcher",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/event-dispatcher.git",
"reference": "b869cbf8a15ca6261689de2c28a7d7f2d0706835"
"reference": "58990682ac3fdc1f563b7e705452921372aad11d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/b869cbf8a15ca6261689de2c28a7d7f2d0706835",
"reference": "b869cbf8a15ca6261689de2c28a7d7f2d0706835",
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/58990682ac3fdc1f563b7e705452921372aad11d",
"reference": "58990682ac3fdc1f563b7e705452921372aad11d",
"shasum": ""
},
"require": {
@@ -3826,20 +3816,20 @@
],
"description": "Symfony EventDispatcher Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-14T10:03:57+00:00"
},
{
"name": "symfony/filesystem",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/filesystem.git",
"reference": "25b135bea251829e3db6a77d773643408b575ed4"
"reference": "253a4490b528597aa14d2bf5aeded6f5e5e4a541"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/25b135bea251829e3db6a77d773643408b575ed4",
"reference": "25b135bea251829e3db6a77d773643408b575ed4",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/253a4490b528597aa14d2bf5aeded6f5e5e4a541",
"reference": "253a4490b528597aa14d2bf5aeded6f5e5e4a541",
"shasum": ""
},
"require": {
@@ -3875,20 +3865,20 @@
],
"description": "Symfony Filesystem Component",
"homepage": "https://symfony.com",
"time": "2017-12-14T19:40:10+00:00"
"time": "2018-02-22T10:48:49+00:00"
},
{
"name": "symfony/polyfill-mbstring",
"version": "v1.6.0",
"version": "v1.7.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296"
"reference": "78be803ce01e55d3491c1397cf1c64beb9c1b63b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296",
"reference": "2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/78be803ce01e55d3491c1397cf1c64beb9c1b63b",
"reference": "78be803ce01e55d3491c1397cf1c64beb9c1b63b",
"shasum": ""
},
"require": {
@@ -3900,7 +3890,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.6-dev"
"dev-master": "1.7-dev"
}
},
"autoload": {
@@ -3934,20 +3924,20 @@
"portable",
"shim"
],
"time": "2017-10-11T12:05:26+00:00"
"time": "2018-01-30T19:27:44+00:00"
},
{
"name": "symfony/translation",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/translation.git",
"reference": "4c5d5582baf2829751a5207659329c1f52eedeb6"
"reference": "80e19eaf12cbb546ac40384e5c55c36306823e57"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/translation/zipball/4c5d5582baf2829751a5207659329c1f52eedeb6",
"reference": "4c5d5582baf2829751a5207659329c1f52eedeb6",
"url": "https://api.github.com/repos/symfony/translation/zipball/80e19eaf12cbb546ac40384e5c55c36306823e57",
"reference": "80e19eaf12cbb546ac40384e5c55c36306823e57",
"shasum": ""
},
"require": {
@@ -4002,20 +3992,20 @@
],
"description": "Symfony Translation Component",
"homepage": "https://symfony.com",
"time": "2017-12-12T08:27:14+00:00"
"time": "2018-02-22T06:28:18+00:00"
},
{
"name": "symfony/yaml",
"version": "v3.4.2",
"version": "v3.4.6",
"source": {
"type": "git",
"url": "https://github.com/symfony/yaml.git",
"reference": "afe0cd38486505c9703707707d91450cfc1bd536"
"reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/yaml/zipball/afe0cd38486505c9703707707d91450cfc1bd536",
"reference": "afe0cd38486505c9703707707d91450cfc1bd536",
"url": "https://api.github.com/repos/symfony/yaml/zipball/6af42631dcf89e9c616242c900d6c52bd53bd1bb",
"reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb",
"shasum": ""
},
"require": {
@@ -4060,7 +4050,7 @@
],
"description": "Symfony Yaml Component",
"homepage": "https://symfony.com",
"time": "2017-12-11T20:38:23+00:00"
"time": "2018-02-16T09:50:28+00:00"
},
{
"name": "theseer/tokenizer",
@@ -4171,6 +4161,6 @@
"ext-openssl": "*"
},
"platform-dev": {
"php": ">=7.0"
"php": ">=5.6 || >=7.0"
}
}

View File

@@ -8,17 +8,17 @@ doing development.
Create your own github account.
You may fork/clone the Red repository from [https://github.com/redmatrix/hubzilla.git](https://github.com/redmatrix/hubzilla.git).
You may fork/clone the $Projectname repository from [https://framagit.org/hubzilla/core.git](https://framagit.org/hubzilla/core.git).
Follow the instructions provided here: [http://help.github.com/fork-a-repo/](http://help.github.com/fork-a-repo/)
to create and use your own tracking fork on github
to create and use your own tracking fork on framagit
Then go to your github page and create a "Pull request" when you are ready
Then go to your framagit page and create a "Pull request" when you are ready
to notify us to merge your work.
**Translations**
Our translations are managed through Transifex. If you wish to help out translating $Projectname to another language, sign up on transifex.com, visit [https://www.transifex.com/projects/p/red-matrix/](https://www.transifex.com/projects/p/red-matrix/) and request to join one of the existing language teams or create a new one. Notify one of the core developers when you have a translation update which requires merging, or ask about merging it yourself if you're comfortable with git and PHP. We have a string file called 'messages.po' which is gettext compliant and a handful of email templates, and from there we automatically generate the application's language files.
Our translations are managed through Transifex. If you wish to help out translating $Projectname to another language, sign up on transifex.com, visit [https://www.transifex.com/projects/p/hubzilla/](https://www.transifex.com/projects/p/hubzilla/) and request to join one of the existing language teams or create a new one. Notify one of the core developers when you have a translation update which requires merging, or ask about merging it yourself if you're comfortable with git and PHP. We have a string file called 'messages.po' which is gettext compliant and a handful of email templates, and from there we automatically generate the application's language files.
[Translations - More Info](help/Translations)

View File

@@ -4,13 +4,13 @@ Translating $Projectname
Translation Process
-------------------
The strings used in the UI of Hubzilla is translated at [Transifex][1] and then
The strings used in the UI of $Projectname is translated at [Transifex][1] and then
included in the git repository at github. If you want to help with translation
for any language, be it correcting terms or translating Hubzilla to a
for any language, be it correcting terms or translating $Projectname to a
currently not supported language, please register an account at transifex.com
and contact the Redmatrix translation team there.
Translating Hubzilla is simple. Just use the online tool at transifex. If you
Translating $Projectname is simple. Just use the online tool at transifex. If you
don't want to deal with git & co. that is fine, we check the status of the
translations regularly and import them into the source tree at github so that
others can use them.
@@ -26,32 +26,32 @@ tree.
If you want to get your work into the source tree yourself, feel free to do so
and contact us with and question that arises. The process is simple and
Hubzilla ships with all the tools necessary.
$Projectname ships with all the tools necessary.
The location of the translated files in the source tree is
/view/LNG-CODE/
where LNG-CODE is the language code used, e.g. de for German or fr for French.
For the email templates (the *.tpl files) just place them into the directory
and you are done. The translated strings come as a "hmessages.po" file from
transifex which needs to be translated into the PHP file Hubzilla uses. To do
transifex which needs to be translated into the PHP file $Projectname uses. To do
so, place the file in the directory mentioned above and use the "po2php"
utility from the util directory of your Hubzilla installation.
utility from the util directory of your $Projectname installation.
Assuming you want to convert the German localization which is placed in
view/de/hmessages.po you would do the following.
1. Navigate at the command prompt to the base directory of your
Hubzilla installation
$Projectname installation
2. Execute the po2php script, which will place the translation
in the hstrings.php file that is used by Hubzilla.
in the hstrings.php file that is used by $Projectname.
$> php util/po2php.php view/de/hmessages.po
The output of the script will be placed at view/de/hstrings.php where
froemdoca os expecting it, so you can test your translation mmediately.
3. Visit your Hubzilla page to check if it still works in the language you
3. Visit your $Projectname page to check if it still works in the language you
just translated. If not try to find the error, most likely PHP will give
you a hint in the log/warnings.about the error.
@@ -62,16 +62,16 @@ view/de/hmessages.po you would do the following.
$> php view/de/hstrings.php
4. commit the two files with a meaningful commit message to your git
repository, push it to your fork of the Hubzilla repository at github and
repository, push it to your fork of the $Projectname repository at github and
issue a pull request for that commit.
Utilities
---------
Additional to the po2php script there are some more utilities for translation
in the "util" directory of the Hubzilla source tree. If you only want to
translate Hubzilla into another language you wont need any of these tools most
likely but it gives you an idea how the translation process of Hubzilla
in the "util" directory of the $Projectname source tree. If you only want to
translate $Projectname into another language you wont need any of these tools most
likely but it gives you an idea how the translation process of $Projectname
works.
For further information see the utils/README file.
@@ -79,7 +79,7 @@ For further information see the utils/README file.
Known Problems
--------------
* Hubzilla uses the language setting of the visitors browser to determain the
* $Projectname uses the language setting of the visitors browser to determain the
language for the UI. Most of the time this works, but there are some known
quirks.
* the early translations are based on the friendica translations, if you
@@ -87,7 +87,7 @@ Known Problems
Links
------
[1]: http://www.transifex.com/projects/p/red-matrix/
[1]: http://www.transifex.com/projects/p/hubzilla/
#include doc/macros/main_footer.bb;

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