aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <redmatrix@redmatrix.me>2015-04-08 23:12:39 -0700
committerfriendica <redmatrix@redmatrix.me>2015-04-08 23:12:39 -0700
commit4289c8adb2ae9e09a2ebce301c8c6869fd831246 (patch)
treeb501e88e01494ef8b5d32e831315524735e15ace
parent7bec4b313a7a553e6df3e24289cf894f3d70a94e (diff)
downloadvolse-hubzilla-4289c8adb2ae9e09a2ebce301c8c6869fd831246.tar.gz
volse-hubzilla-4289c8adb2ae9e09a2ebce301c8c6869fd831246.tar.bz2
volse-hubzilla-4289c8adb2ae9e09a2ebce301c8c6869fd831246.zip
fix selector when sys channel active
-rw-r--r--include/text.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/text.php b/include/text.php
index 1f383d8b3..ef38c03d7 100644
--- a/include/text.php
+++ b/include/text.php
@@ -98,6 +98,13 @@ function z_input_filter($channel_id,$s,$type = 'text/bbcode') {
return escape_tags($s);
if($type == 'text/plain')
return escape_tags($s);
+
+ $a = get_app();
+ if($a->is_sys) {
+ $sys = get_sys_channel();
+ $channel_id = $sys['channel_id'];
+ }
+
$r = q("select account_id, account_roles, channel_pageflags from account left join channel on channel_account_id = account_id where channel_id = %d limit 1",
intval($channel_id)
);
@@ -1611,6 +1618,12 @@ function layout_select($channel_id, $current = '') {
function mimetype_select($channel_id, $current = 'text/bbcode') {
+ $a = get_app();
+ if($a->is_sys) {
+ $sys = get_sys_channel();
+ $channel_id = $sys['channel_id'];
+ }
+
$x = array(
'text/bbcode',
'text/html',