aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzottel <github@zottel.net>2015-09-10 08:32:33 +0200
committerzottel <github@zottel.net>2015-09-10 08:32:33 +0200
commit174d55cf3dd32ad767da1ee399b77b90dfbfed99 (patch)
tree8254b2c2dcd5e1697cf1a6983ddc73d33c4ad552
parent2417396a93fd14eae56dc8d463b2af14208564d6 (diff)
parentf2889d24e6bef4c530b233d0b4359d140574b57b (diff)
downloadvolse-hubzilla-174d55cf3dd32ad767da1ee399b77b90dfbfed99.tar.gz
volse-hubzilla-174d55cf3dd32ad767da1ee399b77b90dfbfed99.tar.bz2
volse-hubzilla-174d55cf3dd32ad767da1ee399b77b90dfbfed99.zip
Merge remote-tracking branch 'upstream/master'
-rwxr-xr-xboot.php2
-rw-r--r--doc/bugs.bb36
-rw-r--r--include/conversation.php1
-rw-r--r--include/message.php1
-rw-r--r--include/widgets.php6
-rw-r--r--mod/editblock.php1
-rw-r--r--mod/editlayout.php1
-rw-r--r--mod/editpost.php1
-rw-r--r--mod/editwebpage.php1
-rwxr-xr-xmod/like.php15
-rw-r--r--mod/network.php19
-rw-r--r--mod/profile_photo.php5
-rw-r--r--mod/zfinger.php2
-rwxr-xr-xview/tpl/jot-header.tpl3
14 files changed, 69 insertions, 25 deletions
diff --git a/boot.php b/boot.php
index 4dafde7f2..bc8baf818 100755
--- a/boot.php
+++ b/boot.php
@@ -82,7 +82,7 @@ $DIRECTORY_FALLBACK_SERVERS = array(
'https://zotid.net',
'https://red.zottel.red',
'https://gravizot.de',
- 'https://my.federated.social',
+ 'https://my.federated.social'
);
diff --git a/doc/bugs.bb b/doc/bugs.bb
index 9fefdef08..1a27e66ba 100644
--- a/doc/bugs.bb
+++ b/doc/bugs.bb
@@ -1,31 +1,45 @@
[h2]Bugs, Issues, and things that go bump in the night...[/h2]
-
[h3]Something went wrong! Who is charge of fixing it?[/h3]
-This software is open source and was built by and is maintained by unpaid volunteers. So the quick answer is that nobody is in charge of fixing things. However, some of us have worked long and hard to provide a quality experience for you and don't wish to see you in discomfort because of a software issue or bug.
+[b]Hubzilla Community Server[/b]
+
+Hubzilla Community Server is open source software which is maintained by "the community" - essentially unpaid volunteers.
+
+[b]Hubzilla Enterprise Server[/b]
-The first thing you need to do is talk to your hub administrator - the person who runs and manages your site. They are in the unique position of having access to the internal software and database and [b]logfiles[/b] and will need to be involved in fixing your problem. Other people "on the net" can't really help with this. The first thing [b]they[/b] need to do is look at their logs and/or try to reproduce the problem. So try to be as helpful and courteous as possible in helping them look into the problem.
+Hubzilla Enterprise Server is commercial software with a variety of support plans depending on the specific license terms.
-To find your site administrator (if you don't know who they are) please look at [url=[baseurl]/siteinfo]this page[/url]. If they have not provided any contact info on that page or provided an "Impressum" there, see [url=[baseurl]/siteinfo/json]this site info summary[/url] under the heading "admin:".
+
+The first thing you need to do is talk to your hub administrator - the person who runs and manages your site. They are in the unique position of having access to the internal software and database and [b]logfiles[/b] and will need to be involved in fixing your problem. Other people "on the net" can't really help with this. The first thing the hub administrator needs to do is look at their logs and/or try to reproduce the problem. So try to be as helpful and courteous as possible in helping them look into the problem.
-[h3]I'm a site administrator; what do I do?[/h3]
+To find your hub administrator (if you don't know who they are) please look at [url=[baseurl]/siteinfo]this page[/url]. If they have not provided any contact info on that page or provided an "Impressum" there, see [url=[baseurl]/siteinfo/json]this site info summary[/url] under the heading "admin:".
-It's your site, fix it! OK, sometimes it isn't that easy. There could be other sites involved, and the problem may not even be on your site but elsewhere in the network. Try to pin down the communication endpoints (hubs or sites) involved in the problem and contact the administrator of that site or those sites. Please try and provide an event time of when things went wrong so it can be found in the logs. Work with the other administrator(s) to find the cause of the problem. Logfiles are your friend. When something happens in the software that we didn't expect, it is nearly always logged.
+[h3]I'm a hub administrator; what do I do?[/h3]
+
+The software instructions which provide this server are open source and are available for your inspection. If an error message was reported, often one can do a search on the source files for that error message and find out what triggered it. With this information and the site logfiles it may be possible to figure out the sequence of events leading to the error. There could also be other sites involved, and the problem may not even be on your site but elsewhere in the network. Try to pin down the communication endpoints (hubs or sites) involved in the problem and contact the administrator of that site or those sites. Please try and provide an event time of when things went wrong so it can be found in the logs. Work with the other administrator(s) to try and find the cause of the problem. Logfiles are your friend. When something happens in the software that we didn't expect, it is nearly always logged.
[h3]The white screen of death[/h3]
-If you get a blank white screen when doing something, this is almost always a code or syntax error. There are instructions in your .htconfig.php file for enabling syntax logging. Do this and repeat the sequence which led to the error and it should log the offending line of code. Hopefully you will be able to fix the problem with this information. When you do, please submit the fix "upstream" so that we can share the fix with the rest of the project members. This is the key benefit of using open source software - we share with each other and everybody benefits.
+If you get a blank white screen when doing something, this is almost always a code or syntax error. There are instructions in your .htconfig.php file for enabling syntax logging. We recommend all sites use this. With syntax logging enabled repeat the sequence which led to the error and it should log the offending line of code. Hopefully you will be able to fix the problem with this information. When you do, please submit the fix "upstream" so that we can share the fix with the rest of the project members and other communities. This is a key benefit of using open source software - we share with each other and everybody benefits.
[h3]I'm stumped. I can't figure out what is wrong.[/h3]
-At this point it might be worthwhile discussing the issue on one of the online forums. There may be several of these and some may be more suited to your spoken language. As a last resort, try "Channel One", which is in English.
+[b]Hubzilla Enterprise Server[/b]
+
+Please make contact with the vendor - who will have provided you with support contact details. Preferably this contact will be made by the hub administrator so that he/she can assist us in collecting the necessary issue details. We will assign a ticket and notify you of progress.
-Other developers may need to find out more, so do your homework and document what is happening and everything you've tried. Don't say "I did xyz and it didn't work." That doesn't tell us anything. Tell us precisely what steps you took and what you expected the result to be, and precisely what happened as a result. If there were any error messages, don't say "there was an error message". Tell us exactly what the message said.
-If the project developers can't help you right away, understand that they are volunteers and may have a lot of other work and demands on their time. At this point you need to file a bug report. You will need an account on github.com to do this. So register, and then visit https://github.com/redmatrix/hubzilla/issues
+[b]Hubzilla Community Server[/b]
+
+At this point it might be worthwhile discussing the issue on one of the online forums. There may be several of these and some may be more suited to your spoken language. As a last resort, try "Channel One", which is in English.
+
+If the community developers can't help you right away, understand that they are volunteers and may have a lot of other work and demands on their time. At this point you need to file a bug report. You will need an account on github.com to do this. So register, and then visit https://github.com/redmatrix/hubzilla/issues
. Create an issue here and provide all the same information that you provided online. Don't leave out anything.
Then you wait. If it's a high profile issue, it may get fixed quickly. But nobody is in charge of fixing bugs. If it lingers without resolution, please spend some more time investigating the problem. Ask about anything you don't understand related to the behaviour. You will learn more about how the software works and quite possibly figure out why it isn't working now. Ultimately it is somebody in the community who is going to fix this and you are a member of the community; and this is how the open source process works.
-And just a word of warning. If you file 10 or 20 or 40 bugs on your first day looking at the project and without exploring how the software was supposed to work in the first place, you will probably be ignored. This is a public project and we are unfortunately frequented by "whingers" who like to waste our time complaining about stuff. Don't be one of them. The more helpful and courteous you are, the more helpful and courteous we will be in return. This applies to everything you do in life and is only mentioned here as a reminder.
+
+[b]In either case[/b]
+
+Other developers working to fix the problem may need to find out more, so do your homework and document what is happening and everything you've tried. Don't say "I did xyz and it didn't work." That doesn't tell us anything. Tell us precisely what steps you took and what you expected the result to be, and precisely what happened as a result. If there were any error messages, don't say "there was an error message". Tell us exactly what the message said.
\ No newline at end of file
diff --git a/include/conversation.php b/include/conversation.php
index a3fdf39df..fb8ef8585 100644
--- a/include/conversation.php
+++ b/include/conversation.php
@@ -1137,6 +1137,7 @@ function status_editor($a, $x, $popup = false) {
'$newpost' => 'true',
'$baseurl' => $a->get_baseurl(true),
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
+ '$pretext' => ((x($x,'pretext')) ? $x['pretext'] : ''),
'$geotag' => $geotag,
'$nickname' => $x['nickname'],
'$ispublic' => t('Visible to <strong>everybody</strong>'),
diff --git a/include/message.php b/include/message.php
index 396e3162c..efe1a7710 100644
--- a/include/message.php
+++ b/include/message.php
@@ -49,6 +49,7 @@ function send_message($uid = 0, $recipient='', $body='', $subject='', $replyto='
// look for any existing conversation structure
+
if(strlen($replyto)) {
$r = q("select convid from mail where channel_id = %d and ( mid = '%s' or parent_mid = '%s' ) limit 1",
intval(local_channel()),
diff --git a/include/widgets.php b/include/widgets.php
index 8c5e92140..5e40bf54a 100644
--- a/include/widgets.php
+++ b/include/widgets.php
@@ -1007,7 +1007,9 @@ function widget_forums($arr) {
$perms_sql = item_permissions_sql(local_channel()) . item_normal();
- $r1 = q("select * from abook left join xchan on abook_xchan = xchan_hash where xchan_pubforum = 1 and abook_channel = %d order by xchan_name $limit ",
+ $r1 = q("select * from abook left join xchan on abook_xchan = xchan_hash where ( xchan_pubforum = 1 or ((abook_their_perms & %d ) != 0 and (abook_their_perms & %d ) = 0) ) and abook_channel = %d order by xchan_name $limit ",
+ intval(PERMS_W_TAGWALL),
+ intval(PERMS_W_STREAM),
intval(local_channel())
);
if(! $r1)
@@ -1034,7 +1036,7 @@ function widget_forums($arr) {
foreach($r1 as $rr) {
if($unseen && (! intval($rr['unseen'])))
continue;
- $o .= '<li><span class="pull-right">' . ((intval($rr['unseen'])) ? intval($rr['unseen']) : '') . '</span><a href="network?f=&cid=' . $rr['abook_id'] . '" ><img src="' . $rr['xchan_photo_s'] . '" style="width: 16px; height: 16px;" /> ' . $rr['xchan_name'] . '</a></li>';
+ $o .= '<li><span class="pull-right">' . ((intval($rr['unseen'])) ? intval($rr['unseen']) : '') . '</span><a href="network?f=&pf=1&cid=' . $rr['abook_id'] . '" ><img src="' . $rr['xchan_photo_s'] . '" style="width: 16px; height: 16px;" /> ' . $rr['xchan_name'] . '</a></li>';
}
$o .= '</ul></div>';
}
diff --git a/mod/editblock.php b/mod/editblock.php
index b4d954ef5..9269676b1 100644
--- a/mod/editblock.php
+++ b/mod/editblock.php
@@ -111,6 +111,7 @@ function editblock_content(&$a) {
$a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array(
'$baseurl' => $a->get_baseurl(),
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
+ '$pretext' => '',
'$ispublic' => '&nbsp;', // t('Visible to <strong>everybody</strong>'),
'$geotag' => '',
'$nickname' => $channel['channel_address'],
diff --git a/mod/editlayout.php b/mod/editlayout.php
index 6ea7f4100..fc68cfe3c 100644
--- a/mod/editlayout.php
+++ b/mod/editlayout.php
@@ -105,6 +105,7 @@ function editlayout_content(&$a) {
$a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array(
'$baseurl' => $a->get_baseurl(),
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
+ '$pretext' => '',
'$ispublic' => '&nbsp;', // t('Visible to <strong>everybody</strong>'),
'$geotag' => $geotag,
'$nickname' => $channel['channel_address'],
diff --git a/mod/editpost.php b/mod/editpost.php
index daca7c154..d4dc35ef8 100644
--- a/mod/editpost.php
+++ b/mod/editpost.php
@@ -47,6 +47,7 @@ function editpost_content(&$a) {
$a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array(
'$baseurl' => $a->get_baseurl(),
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
+ '$pretext' => '',
'$ispublic' => '&nbsp;', // t('Visible to <strong>everybody</strong>'),
'$geotag' => $geotag,
'$nickname' => $channel['channel_address'],
diff --git a/mod/editwebpage.php b/mod/editwebpage.php
index 974e8cc38..0192fd9c0 100644
--- a/mod/editwebpage.php
+++ b/mod/editwebpage.php
@@ -146,6 +146,7 @@ function editwebpage_content(&$a) {
$a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array(
'$baseurl' => $a->get_baseurl(),
'$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'),
+ '$pretext' => '',
'$ispublic' => '&nbsp;', // t('Visible to <strong>everybody</strong>'),
'$geotag' => $geotag,
'$nickname' => $channel['channel_address'],
diff --git a/mod/like.php b/mod/like.php
index 42ff9bb8a..87f012874 100755
--- a/mod/like.php
+++ b/mod/like.php
@@ -222,10 +222,17 @@ function like_content(&$a) {
q("delete from likes where id = %d limit 1",
intval($z[0]['id'])
);
- drop_item($z[0]['iid'],false);
- if($interactive) {
- notice( t('Previous action reversed.') . EOL);
- return $o;
+ if($z[0]['i_mid']) {
+ $r = q("select id from item where mid = '%s' and uid = %d limit 1",
+ dbesc($z[0]['i_mid']),
+ intval($ch[0]['channel_id'])
+ );
+ if($r)
+ drop_item($r[0]['id'],false);
+ if($interactive) {
+ notice( t('Previous action reversed.') . EOL);
+ return $o;
+ }
}
killme();
}
diff --git a/mod/network.php b/mod/network.php
index d5e305687..82c68424c 100644
--- a/mod/network.php
+++ b/mod/network.php
@@ -115,6 +115,8 @@ function network_content(&$a, $update = 0, $load = false) {
$file = ((x($_GET,'file')) ? $_GET['file'] : '');
+ $deftag = '';
+
if(x($_GET,'search') || x($_GET,'file'))
$nouveau = true;
if($cid) {
@@ -130,7 +132,10 @@ function network_content(&$a, $update = 0, $load = false) {
goaway($a->get_baseurl(true) . '/network');
// NOTREACHED
}
- $def_acl = array('allow_cid' => '<' . $r[0]['abook_xchan'] . '>');
+ if($_GET['pf'] === '1')
+ $deftag = '@' . t('forum') . '+' . intval($cid) . '+';
+ else
+ $def_acl = array('allow_cid' => '<' . $r[0]['abook_xchan'] . '>');
}
if(! $update) {
@@ -153,17 +158,21 @@ function network_content(&$a, $update = 0, $load = false) {
'deny_gid' => $channel['channel_deny_gid']
);
+ $private_editing = ((($group || $cid) && (! intval($_GET['pf']))) ? true : false);
+
$x = array(
'is_owner' => true,
'allow_location' => ((intval(get_pconfig($channel['channel_id'],'system','use_browser_location'))) ? '1' : ''),
'default_location' => $channel['channel_location'],
'nickname' => $channel['channel_address'],
- 'lockstate' => (($group || $cid || $channel['channel_allow_cid'] || $channel['channel_allow_gid'] || $channel['channel_deny_cid'] || $channel['channel_deny_gid']) ? 'lock' : 'unlock'),
- 'acl' => populate_acl((($group || $cid) ? $def_acl : $channel_acl)),
- 'bang' => (($group || $cid) ? '!' : ''),
+ 'lockstate' => (($private_editing || $channel['channel_allow_cid'] || $channel['channel_allow_gid'] || $channel['channel_deny_cid'] || $channel['channel_deny_gid']) ? 'lock' : 'unlock'),
+ 'acl' => populate_acl((($private_editing) ? $def_acl : $channel_acl)),
+ 'bang' => (($private_editing) ? '!' : ''),
'visitor' => true,
'profile_uid' => local_channel()
);
+ if($deftag)
+ $x['pretext'] = $deftag;
$status_editor = status_editor($a,$x);
$o .= $status_editor;
@@ -223,7 +232,7 @@ function network_content(&$a, $update = 0, $load = false) {
if($r) {
$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(
- '$title' => t('Connection: ') . $r[0]['xchan_name']
+ '$title' => (($_GET['pf'] === '1') ? t('Forum: ') : t('Connection: ')) . $r[0]['xchan_name']
));
$o = $tabs;
$o .= $title;
diff --git a/mod/profile_photo.php b/mod/profile_photo.php
index 9f57c3b9d..7564a3f69 100644
--- a/mod/profile_photo.php
+++ b/mod/profile_photo.php
@@ -238,16 +238,19 @@ function profile_photo_post(&$a) {
notice( t('Image upload failed.') . EOL );
return;
}
+ $os_storage = false;
+
foreach($i as $ii) {
if(intval($ii['scale']) < 2) {
$smallest = intval($ii['scale']);
+ $os_storage = intval($ii['os_storage']);
$imagedata = $ii['data'];
$filetype = $ii['type'];
}
}
}
-// $imagedata = @file_get_contents($src);
+ $imagedata = (($os_storage) ? @file_get_contents($imagedata) : $imagedata);
$ph = photo_factory($imagedata, $filetype);
if(! $ph->is_valid()) {
diff --git a/mod/zfinger.php b/mod/zfinger.php
index ba80fc9b6..54ea52bc9 100644
--- a/mod/zfinger.php
+++ b/mod/zfinger.php
@@ -116,7 +116,7 @@ function zfinger_init(&$a) {
$t = q("select abook_my_perms from abook where abook_channel = %d and abook_self = 1 limit 1",
intval($e['channel_id'])
);
- if($t && ($t[0]['abook_my_perms'] & PERMS_W_TAGWALL))
+ if(($t) && (($t[0]['abook_my_perms'] & PERMS_W_TAGWALL) && (! ($t[0]['abook_my_perms'] & PERMS_W_STREAM))))
$public_forum = true;
}
diff --git a/view/tpl/jot-header.tpl b/view/tpl/jot-header.tpl
index 49369ab63..7e12c6bb3 100755
--- a/view/tpl/jot-header.tpl
+++ b/view/tpl/jot-header.tpl
@@ -3,6 +3,7 @@
var editor = false;
var textlen = 0;
var plaintext = '{{$editselect}}';
+var pretext = '{{$pretext}}';
function initEditor(cb){
if (editor==false){
@@ -21,6 +22,8 @@ function initEditor(cb){
});
$(".jothidden").show();
if (typeof cb!="undefined") cb();
+ if(pretext.length)
+ addeditortext(pretext);
return;
}
tinyMCE.init({