From 8e3a16bcdddb3e978bb984a050f837912de4f463 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Tue, 25 Feb 2014 21:06:47 +0000 Subject: Update channel permissions to full ints --- boot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index fbab83f05..26811a55e 100755 --- a/boot.php +++ b/boot.php @@ -47,7 +47,7 @@ define ( 'RED_PLATFORM', 'Red Matrix' ); define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R'); define ( 'ZOT_REVISION', 1 ); -define ( 'DB_UPDATE_VERSION', 1098 ); +define ( 'DB_UPDATE_VERSION', 1099 ); define ( 'EOL', '
' . "\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); -- cgit v1.2.3 From 08313bac6c7ce9f87b6b6ddf23cc5c4d50747aa1 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 25 Feb 2014 14:12:51 -0800 Subject: allow personalised page layouts for modules. --- boot.php | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index fbab83f05..68b7c8d3c 100755 --- a/boot.php +++ b/boot.php @@ -1807,8 +1807,18 @@ function construct_page(&$a) { // in case a page has overloaded a module, see if we already have a layout defined // otherwise, if a pdl file exists for this module, use it - if((! count($a->layout)) && ($p = theme_include('mod_' . $a->module . '.pdl')) != '') - comanche_parser($a,@file_get_contents($p)); + if(! count($a->layout)) { + $n = 'mod_' . $a->module . '.pdl' ; + $u = get_theme_uid(); + if((! $u) && $a->profile_uid) + $u = $a->profile_uid; + if($u) + $s = get_pconfig($u,'system',$n); + if((! $s) && (($p = theme_include($n)) != '')) + $s = @file_get_contents($p); + if($s) + comanche_parser($a,$s); + } $comanche = ((count($a->layout)) ? true : false); -- cgit v1.2.3 From 2c72e49d1f63404b464f284d86ce2dce7f2eb493 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 25 Feb 2014 17:55:30 -0800 Subject: more chatroom discovery --- boot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 56a87ca9a..381f1eea0 100755 --- a/boot.php +++ b/boot.php @@ -47,7 +47,7 @@ define ( 'RED_PLATFORM', 'Red Matrix' ); define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R'); define ( 'ZOT_REVISION', 1 ); -define ( 'DB_UPDATE_VERSION', 1099 ); +define ( 'DB_UPDATE_VERSION', 1100 ); define ( 'EOL', '
' . "\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); -- cgit v1.2.3 From e7e97e578b3069b8d24ea2a18ce4d3648b402ca3 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 25 Feb 2014 19:48:13 -0800 Subject: put bookmarked chatrooms into poco --- boot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 381f1eea0..c37bd57b9 100755 --- a/boot.php +++ b/boot.php @@ -47,7 +47,7 @@ define ( 'RED_PLATFORM', 'Red Matrix' ); define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R'); define ( 'ZOT_REVISION', 1 ); -define ( 'DB_UPDATE_VERSION', 1100 ); +define ( 'DB_UPDATE_VERSION', 1101 ); define ( 'EOL', '
' . "\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); -- cgit v1.2.3 From 102521844b3d6f31d0d801b0d0c89241c2c621af Mon Sep 17 00:00:00 2001 From: friendica Date: Thu, 27 Feb 2014 20:48:10 -0800 Subject: put schemas in Comanche (this requires theme support (!)) --- boot.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index c37bd57b9..d080b7774 100755 --- a/boot.php +++ b/boot.php @@ -1678,10 +1678,11 @@ function current_theme(){ function current_theme_url($installing = false) { global $a; $t = current_theme(); - $uid = ''; - $uid = (($a->profile_uid) ? '?f=&puid=' . $a->profile_uid : ''); + $opts = ''; + $opts = (($a->profile_uid) ? '?f=&puid=' . $a->profile_uid : ''); + $opts .= ((x($a->layout,'schema')) ? '&schema=' . $a->layout['schema'] : ''); if(file_exists('view/theme/' . $t . '/php/style.php')) - return('view/theme/' . $t . '/php/style.pcss' . $uid); + return('view/theme/' . $t . '/php/style.pcss' . $opts); return('view/theme/' . $t . '/css/style.css'); } -- cgit v1.2.3 From bf401a5afaca8f96606b22e219bd595646ac9dab Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 2 Mar 2014 00:24:29 -0800 Subject: allow templates to have multiple styles - this would be a bit like having a schema for a template file. At first you'll think this is insane and overly complicated, you'll just have to wait and see what I'm up to. Then it will start to make sense. --- boot.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index d080b7774..1c7e5f147 100755 --- a/boot.php +++ b/boot.php @@ -1852,7 +1852,11 @@ function construct_page(&$a) { require_once('include/js_strings.php'); - head_add_css(((x($a->page,'template')) ? $a->page['template'] : 'default' ) . '.css'); + if(x($a->page,'template_style')) + head_add_css($a->page['template_style'] . '.css'); + else + head_add_css(((x($a->page,'template')) ? $a->page['template'] : 'default' ) . '.css'); + head_add_css('mod_' . $a->module . '.css'); head_add_css(current_theme_url($installing)); -- cgit v1.2.3 From 7baeb451836752a612ca976db04aeffcafeb621d Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 2 Mar 2014 19:40:59 -0800 Subject: some anomolies found when viewing connections in various cases. --- boot.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 1c7e5f147..e2a168156 100755 --- a/boot.php +++ b/boot.php @@ -1810,9 +1810,7 @@ function construct_page(&$a) { if(! count($a->layout)) { $n = 'mod_' . $a->module . '.pdl' ; - $u = get_theme_uid(); - if((! $u) && $a->profile_uid) - $u = $a->profile_uid; + $u = comanche_get_channel_id(); if($u) $s = get_pconfig($u,'system',$n); if((! $s) && (($p = theme_include($n)) != '')) -- cgit v1.2.3 From bfd9f5ec87ed0b21e278ea5c94016623c9985850 Mon Sep 17 00:00:00 2001 From: friendica Date: Mon, 3 Mar 2014 19:15:11 -0800 Subject: enable network/matrix expiration, this should be functional but the options have been reduced/restricted so we're only looking at network posts and ignore anything that is filed, starred, or is resource_type 'photo' (which should not be possible in non-wall posts, but we just want to be sure). Will require the adventurous tester(s) to set 'channel_expire_days' in their channel record. --- boot.php | 2 ++ 1 file changed, 2 insertions(+) (limited to 'boot.php') diff --git a/boot.php b/boot.php index e2a168156..f60d7fc3d 100755 --- a/boot.php +++ b/boot.php @@ -528,6 +528,8 @@ define ( 'ITEM_MENTIONSME', 0x0400); define ( 'ITEM_NOCOMMENT', 0x0800); // commenting/followups are disabled define ( 'ITEM_OBSCURED', 0x1000); // bit-mangled to protect from casual browsing by site admin define ( 'ITEM_VERIFIED', 0x2000); // Signature verification was successful +define ( 'ITEM_RETAINED', 0x4000); // We looked at this item once to decide whether or not to expire it, and decided not to. + // Don't make us evaluate this same item again. /** * * Reverse the effect of magic_quotes_gpc if it is enabled. -- cgit v1.2.3 From 3d49bf0320cd6a35e34da9694d3eb957053845a3 Mon Sep 17 00:00:00 2001 From: friendica Date: Mon, 3 Mar 2014 21:00:42 -0800 Subject: directory sync issues --- boot.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index f60d7fc3d..19d79941c 100755 --- a/boot.php +++ b/boot.php @@ -47,7 +47,7 @@ define ( 'RED_PLATFORM', 'Red Matrix' ); define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R'); define ( 'ZOT_REVISION', 1 ); -define ( 'DB_UPDATE_VERSION', 1101 ); +define ( 'DB_UPDATE_VERSION', 1102 ); define ( 'EOL', '
' . "\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); @@ -323,11 +323,10 @@ define ( 'POLL_OVERWRITE', 0x8000); // If you vote twice remove the prior define ( 'UPDATE_FLAGS_UPDATED', 0x0001); +define ( 'UPDATE_FLAGS_FORCED', 0x0002); define ( 'UPDATE_FLAGS_DELETED', 0x1000); - - /** * Maximum number of "people who like (or don't like) this" that we will list by name */ -- cgit v1.2.3 From 86d60f572f6accb086f7cd4271ababde2c5d3669 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 4 Mar 2014 14:35:42 -0800 Subject: change flags for one-way connections from hidden to unconnected so we can still use hidden for - well hiding connections --- boot.php | 1 + 1 file changed, 1 insertion(+) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 19d79941c..863085526 100755 --- a/boot.php +++ b/boot.php @@ -290,6 +290,7 @@ define ( 'ABOOK_FLAG_IGNORED' , 0x0002); define ( 'ABOOK_FLAG_HIDDEN' , 0x0004); define ( 'ABOOK_FLAG_ARCHIVED' , 0x0008); define ( 'ABOOK_FLAG_PENDING' , 0x0010); +define ( 'ABOOK_FLAG_UNCONNECTED', 0x0020); define ( 'ABOOK_FLAG_SELF' , 0x0080); -- cgit v1.2.3 From 8c7e076dae46a81e38620048d1fe3894c1a6d70e Mon Sep 17 00:00:00 2001 From: friendica Date: Thu, 6 Mar 2014 01:29:42 -0800 Subject: bring friends back --- boot.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 863085526..f4774c4ba 100755 --- a/boot.php +++ b/boot.php @@ -47,7 +47,7 @@ define ( 'RED_PLATFORM', 'Red Matrix' ); define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R'); define ( 'ZOT_REVISION', 1 ); -define ( 'DB_UPDATE_VERSION', 1102 ); +define ( 'DB_UPDATE_VERSION', 1103 ); define ( 'EOL', '
' . "\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); -- cgit v1.2.3 From 70ff71c03b2e9663b4b6e3a536cd726749039a08 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Fri, 7 Mar 2014 21:31:19 +0000 Subject: Create a sys chan for hubs that already exist too. --- boot.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'boot.php') diff --git a/boot.php b/boot.php index f4774c4ba..e368896ca 100755 --- a/boot.php +++ b/boot.php @@ -1179,6 +1179,13 @@ function check_config(&$a) { $a->set_baseurl($a->get_baseurl()); + // Make sure each site has a system channel. This is now created on install + // so we just need to keep this around a couple of weeks until the hubs that + // already exist have one + $syschan_exists = get_sys_channel(); + if (! $syschan_exists) + create_sys_channel(); + if($build != DB_UPDATE_VERSION) { $stored = intval($build); if(! $stored) { -- cgit v1.2.3 From d9fd2a20c87d389d93005de6bce56c6c75311977 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 8 Mar 2014 19:11:23 +0000 Subject: is_developer() for those awkward "Don't touch this yet unless you know what you're doing" commits - especially the ones with UI components. --- boot.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index e368896ca..a5a48b2bf 100755 --- a/boot.php +++ b/boot.php @@ -491,7 +491,7 @@ define ( 'ACCOUNT_PENDING', 0x0010 ); define ( 'ACCOUNT_ROLE_ALLOWCODE', 0x0001 ); define ( 'ACCOUNT_ROLE_SYSTEM', 0x0002 ); - +define ( 'ACCOUNT_ROLE_DEVELOPER', 0x0004 ); define ( 'ACCOUNT_ROLE_ADMIN', 0x1000 ); /** @@ -1704,6 +1704,15 @@ function is_site_admin() { return false; } +function is_developer() { + $a = get_app(); + if((intval($_SESSION['authenticated'])) + && (is_array($a->account)) + && ($a->account['account_roles'] & ACCOUNT_ROLE_DEVELOPER)) + return true; + return false; +} + function load_contact_links($uid) { -- cgit v1.2.3